mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2025-09-12 18:03:16 +08:00
Fixed local subscription not working in collections
This commit is contained in:
parent
1ac077101d
commit
51db70a1c3
2
backend/dist/sub-store-parser.loon.min.js
vendored
2
backend/dist/sub-store-parser.loon.min.js
vendored
@ -6,7 +6,7 @@
|
|||||||
* ███████║╚██████╔╝██████╔╝ ███████║ ██║ ╚██████╔╝██║ ██║███████╗
|
* ███████║╚██████╔╝██████╔╝ ███████║ ██║ ╚██████╔╝██║ ██║███████╗
|
||||||
* ╚══════╝ ╚═════╝ ╚═════╝ ╚══════╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝
|
* ╚══════╝ ╚═════╝ ╚═════╝ ╚══════╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝
|
||||||
* Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket!
|
* Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket!
|
||||||
* @updated: 2022/5/25 下午6:14:57
|
* @updated: 2022/5/25 下午10:33:28
|
||||||
* @version: 1.6
|
* @version: 1.6
|
||||||
* @author: Peng-YM
|
* @author: Peng-YM
|
||||||
* @github: https://github.com/Peng-YM/Sub-Store
|
* @github: https://github.com/Peng-YM/Sub-Store
|
||||||
|
@ -318,7 +318,12 @@ async function produceArtifact({ type, item, platform, noProcessor }) {
|
|||||||
const sub = allSubs[name];
|
const sub = allSubs[name];
|
||||||
try {
|
try {
|
||||||
$.info(`正在处理子订阅:${sub.name}...`);
|
$.info(`正在处理子订阅:${sub.name}...`);
|
||||||
const raw = await download(sub.url, sub.ua);
|
let raw;
|
||||||
|
if (sub.source === 'local') {
|
||||||
|
raw = sub.content;
|
||||||
|
} else {
|
||||||
|
raw = await download(sub.url, sub.ua);
|
||||||
|
}
|
||||||
// parse proxies
|
// parse proxies
|
||||||
let currentProxies = ProxyUtils.parse(raw);
|
let currentProxies = ProxyUtils.parse(raw);
|
||||||
if (!noProcessor) {
|
if (!noProcessor) {
|
||||||
|
@ -35,11 +35,13 @@ async function downloadCollection(req, res) {
|
|||||||
const subs = collection['subscriptions'];
|
const subs = collection['subscriptions'];
|
||||||
if (subs.length > 0) {
|
if (subs.length > 0) {
|
||||||
const sub = allSubs[subs[0]];
|
const sub = allSubs[subs[0]];
|
||||||
|
if (sub.source !== 'local') {
|
||||||
const flowInfo = await getFlowHeaders(sub.url);
|
const flowInfo = await getFlowHeaders(sub.url);
|
||||||
if (flowInfo) {
|
if (flowInfo) {
|
||||||
res.set('subscription-userinfo', flowInfo);
|
res.set('subscription-userinfo', flowInfo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (collection) {
|
if (collection) {
|
||||||
try {
|
try {
|
||||||
|
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