q-koa 13.1.9 → 13.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/core/app.js
CHANGED
|
@@ -2195,11 +2195,13 @@ APP.getConfig = (app) => ({
|
|
|
2195
2195
|
Array.isArray(app.appConfig.productionHost)
|
|
2196
2196
|
? app.appConfig.productionHost
|
|
2197
2197
|
: [app.appConfig.productionHost]
|
|
2198
|
-
)
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2198
|
+
)
|
|
2199
|
+
.filter((url) => {
|
|
2200
|
+
return url.match(
|
|
2201
|
+
/^(http:\/\/|https:\/\/)?(\d{1,3}\.){3}\d{1,3}:\d{1,5}/
|
|
2202
|
+
)
|
|
2203
|
+
})
|
|
2204
|
+
.filter((host) => !host.includes(app.appConfig.ip))
|
|
2203
2205
|
|
|
2204
2206
|
Promise.all(
|
|
2205
2207
|
ipHost.map((host) => {
|
package/core/config.js
CHANGED
|
@@ -10,11 +10,7 @@ exports.upsert = async (ctx) => {
|
|
|
10
10
|
id,
|
|
11
11
|
},
|
|
12
12
|
})
|
|
13
|
-
if (
|
|
14
|
-
current_list.some(
|
|
15
|
-
(o) => (o.extra && !lodash.isEmpty(o.extra)) || o.is_front || o.is_cache
|
|
16
|
-
)
|
|
17
|
-
) {
|
|
13
|
+
if (current_list.some((o) => o.is_cache)) {
|
|
18
14
|
appConfig.update()
|
|
19
15
|
}
|
|
20
16
|
}
|
|
@@ -30,11 +26,7 @@ exports.bulkUpdate = async (ctx) => {
|
|
|
30
26
|
id: list.map((item) => item.id),
|
|
31
27
|
},
|
|
32
28
|
})
|
|
33
|
-
if (
|
|
34
|
-
current_list.some(
|
|
35
|
-
(o) => (o.extra && !lodash.isEmpty(o.extra)) || o.is_front || o.is_cache
|
|
36
|
-
)
|
|
37
|
-
) {
|
|
29
|
+
if (current_list.some((o) => o.is_cache)) {
|
|
38
30
|
appConfig.update()
|
|
39
31
|
}
|
|
40
32
|
}
|
|
@@ -393,6 +393,11 @@ module.exports = class Singleton {
|
|
|
393
393
|
cache.reset()
|
|
394
394
|
return await this.queryUrlLink(url_link)
|
|
395
395
|
}
|
|
396
|
+
if (result.errcode === 85403) {
|
|
397
|
+
return {
|
|
398
|
+
expire_time: 0,
|
|
399
|
+
}
|
|
400
|
+
}
|
|
396
401
|
throw new Error(`${result.errcode};${result.errmsg}`)
|
|
397
402
|
}
|
|
398
403
|
return result.url_link_info
|