mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2025-07-13 05:21:48 +08:00
修复组合订阅节点处理错误的问题
This commit is contained in:
parent
710d5b14e5
commit
0fbdbe7b85
@ -273,14 +273,16 @@ function service() {
|
|||||||
let proxies = [];
|
let proxies = [];
|
||||||
for (let i = 0; i < subs.length; i++) {
|
for (let i = 0; i < subs.length; i++) {
|
||||||
const sub = allSubs[subs[i]];
|
const sub = allSubs[subs[i]];
|
||||||
$.info(`正在处理子订阅:${sub.name},进度--${100 * (i + 1 / subs.length).toFixed(1)}% `);
|
$.info(`正在处理子订阅:${sub.name},进度--${100 * ((i + 1) / subs.length).toFixed(1)}% `);
|
||||||
try {
|
try {
|
||||||
const useCache = typeof cache === 'undefined' ? (platform === 'JSON' || platform === 'URI') : cache;
|
const useCache = typeof cache === 'undefined' ? (platform === 'JSON' || platform === 'URI') : cache;
|
||||||
const raw = await getResource(sub.url, useCache);
|
const raw = await getResource(sub.url, useCache);
|
||||||
// parse proxies
|
// parse proxies
|
||||||
proxies = proxies.concat(ProxyUtils.parse(raw));
|
let currentProxies = ProxyUtils.parse(raw)
|
||||||
// apply processors
|
// apply processors
|
||||||
proxies = await ProxyUtils.process(proxies, sub.process || []);
|
currentProxies = await ProxyUtils.process(currentProxies, sub.process || []);
|
||||||
|
// merge
|
||||||
|
proxies = proxies.concat(currentProxies);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
$.error(`处理组合订阅中的子订阅: ${sub.name}时出现错误:${err}! 该订阅已被跳过。`);
|
$.error(`处理组合订阅中的子订阅: ${sub.name}时出现错误:${err}! 该订阅已被跳过。`);
|
||||||
}
|
}
|
||||||
|
4
backend/sub-store.min.js
vendored
4
backend/sub-store.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user