mirror of
https://github.com/alireza0/x-ui.git
synced 2026-03-20 15:55:48 +00:00
完成xray启动
This commit is contained in:
@@ -13,7 +13,7 @@ class HttpUtil {
|
||||
}
|
||||
}
|
||||
|
||||
static async _respToMsg(resp) {
|
||||
static _respToMsg(resp) {
|
||||
const data = resp.data;
|
||||
if (data == null) {
|
||||
return new Msg(true);
|
||||
@@ -227,6 +227,10 @@ class ObjectUtil {
|
||||
for (const key of Object.keys(src)) {
|
||||
if (!src.hasOwnProperty(key)) {
|
||||
continue;
|
||||
} else if (!dest.hasOwnProperty(key)) {
|
||||
continue;
|
||||
} else if (src[key] === undefined) {
|
||||
continue;
|
||||
}
|
||||
if (ignoreEmpty) {
|
||||
dest[key] = src[key];
|
||||
@@ -259,4 +263,11 @@ class ObjectUtil {
|
||||
}
|
||||
}
|
||||
|
||||
static orDefault(obj, defaultValue) {
|
||||
if (obj == null) {
|
||||
return defaultValue;
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user