From 432ede61d9c30539633b2447d379b5aea978dfae Mon Sep 17 00:00:00 2001 From: zhiyu1998 <542716863@qq.com> Date: Sun, 29 Sep 2024 20:22:36 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat:=20acfun=20=E9=80=82=E9=85=8D?= =?UTF-8?q?=E7=9F=AD=E5=8F=B7=E5=8F=91=E9=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/tools.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/tools.js b/apps/tools.js index 2dd2bab..bb046b5 100644 --- a/apps/tools.js +++ b/apps/tools.js @@ -149,7 +149,7 @@ export class tools extends plugin { fnc: "twitter_x", }, { - reg: "(acfun.cn)", + reg: "(acfun.cn|^ac[1-9]{8}$)", fnc: "acfun", }, { @@ -1024,6 +1024,9 @@ export class tools extends plugin { // 适配手机分享:https://m.acfun.cn/v/?ac=32838812&sid=d2b0991bd6ad9c09 if (inputMsg.includes("m.acfun.cn")) { inputMsg = `https://www.acfun.cn/v/ac${ /ac=([^&?]*)/.exec(inputMsg)[1] }`; + } else if (inputMsg.includes("ac")) { + // 如果是 + inputMsg = "https://www.acfun.cn/v/" + /ac\d+/.exec(inputMsg)[0]; } parseUrl(inputMsg).then(res => {