From bce87f4d00505a5acc3a4a3b5c0ebd5e95c7afee Mon Sep 17 00:00:00 2001 From: zhiyu1998 <542716863@qq.com> Date: Mon, 25 Nov 2024 20:16:22 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9E=20fix:=20=E4=BF=AE=E5=A4=8D=20xhs?= =?UTF-8?q?=20=E7=9A=84=E9=83=A8=E5=88=86=E7=BD=91=E9=A1=B5=E5=9C=B0?= =?UTF-8?q?=E5=9D=80=E6=97=A0=E6=B3=95=E8=A7=A3=E6=9E=90=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/tools.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/tools.js b/apps/tools.js index dc31236..2b1a209 100644 --- a/apps/tools.js +++ b/apps/tools.js @@ -1385,7 +1385,7 @@ export class tools extends plugin { // 一般情况下不会出现问题就使用这个正则 id = /noteId=(\w+)/.exec(uri)?.[1] ?? verify?.[1]; // 提取 xsec_source 和 xsec_token 参数 - xsecSource = parsedUrl.searchParams.get("xsec_source") ?? "pc_feed"; + xsecSource = parsedUrl.searchParams.get("xsec_source") || "pc_feed"; xsecToken = parsedUrl.searchParams.get("xsec_token"); }); } else { @@ -1398,7 +1398,7 @@ export class tools extends plugin { const parsedUrl = new URL(xhsUrlMatch[0]); id = /explore\/(\w+)/.exec(msgUrl)?.[1] || /discovery\/item\/(\w+)/.exec(msgUrl)?.[1]; // 提取 xsec_source 和 xsec_token 参数 - xsecSource = parsedUrl.searchParams.get("xsec_source") ?? "pc_feed"; + xsecSource = parsedUrl.searchParams.get("xsec_source") || "pc_feed"; xsecToken = parsedUrl.searchParams.get("xsec_token"); } const downloadPath = `${ this.getCurDownloadPath(e) }`;