fix loon new version issues.

This commit is contained in:
NobyDa 2021-05-16 12:17:01 +08:00
parent 11dbe0de80
commit a25a3a2cc3
1 changed files with 6 additions and 2 deletions

View File

@ -72,8 +72,12 @@ function nobyda() {
})
}
if (isLoon) {
const get = JSON.parse($config.getSubPolicys(groupName));
return get.map(n => n[0].name);
return new Promise((resolve) => {
$config.getSubPolicys(groupName, (b) => {
const get = JSON.parse(b || '[]').map(n => n.name);
resolve(get)
})
})
}
if (isQuanX) {
return new Promise((resolve) => {