mirror of
https://github.com/lush2020/CF-Workers-SUB.git
synced 2026-03-21 02:52:38 +08:00
更新_worker.js,修复对Clash和Singbox订阅内容的匹配逻辑
This commit is contained in:
@@ -425,10 +425,10 @@ async function getSUB(api, request, 追加UA, userAgentHeader) {
|
||||
// 检查响应状态是否为'fulfilled'
|
||||
if (response.status === 'fulfilled') {
|
||||
const content = await response.value || 'null'; // 获取响应的内容
|
||||
if (content.includes('proxies') && content.includes('proxy-groups')) {
|
||||
if (content.includes('proxies:')) {
|
||||
//console.log('Clash订阅: ' + response.apiUrl);
|
||||
订阅转换URLs += "|" + response.apiUrl; // Clash 配置
|
||||
} else if (content.includes('outbounds') && content.includes('inbounds')) {
|
||||
} else if (content.includes('outbounds":') && content.includes('inbounds":')) {
|
||||
//console.log('Singbox订阅: ' + response.apiUrl);
|
||||
订阅转换URLs += "|" + response.apiUrl; // Singbox 配置
|
||||
} else if (content.includes('://')) {
|
||||
|
||||
Reference in New Issue
Block a user