feat: 订阅链接可使用标准参数格式 #noCache&noFlow 或 井号附加 #noCache#noFlow

This commit is contained in:
xream
2024-01-16 08:11:34 +08:00
parent bdc7ee50f7
commit 1bc44ccde8
2 changed files with 9 additions and 5 deletions

View File

@@ -9,9 +9,11 @@ import $ from '@/core/app';
const tasks = new Map();
export default async function download(url, ua, timeout) {
export default async function download(rawUrl, ua, timeout) {
let $arguments = {};
let url = rawUrl.replace(/#noFlow$/, '');
const rawArgs = url.split('#');
url = url.split('#')[0];
if (rawArgs.length > 1) {
try {
// 支持 `#${encodeURIComponent(JSON.stringify({arg1: "1"}))}`