mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2026-04-04 00:23:17 +08:00
feat: 默认查询流量信息的 User-Agent 从 Quantumult%20X/1.0.30 (iPhone14,2; iOS 15.6) 改为 clash; 流量信息缓存逻辑调整
This commit is contained in:
@@ -151,7 +151,7 @@ export default async function download(
|
||||
// try to find in app cache
|
||||
const cached = resourceCache.get(id);
|
||||
if (!noCache && !$arguments?.noCache && cached) {
|
||||
$.info(`使用缓存: ${url}`);
|
||||
$.info(`使用缓存: ${url}, ${userAgent}`);
|
||||
result = cached;
|
||||
if (customCacheKey) {
|
||||
$.info(`URL ${url}\n写入自定义缓存 ${$arguments?.cacheKey}`);
|
||||
@@ -179,7 +179,7 @@ export default async function download(
|
||||
if (headers) {
|
||||
const flowInfo = getFlowField(headers);
|
||||
if (flowInfo) {
|
||||
headersResourceCache.set(url, flowInfo);
|
||||
headersResourceCache.set(id, flowInfo);
|
||||
}
|
||||
}
|
||||
if (body.replace(/\s/g, '').length === 0)
|
||||
|
||||
Reference in New Issue
Block a user