From 6364086a375fb121981579ca18dbc7a017048c25 Mon Sep 17 00:00:00 2001 From: windingwind <33902321+windingwind@users.noreply.github.com> Date: Tue, 30 Jul 2024 13:27:18 +0800 Subject: [PATCH] fix: #854 --- src/modules/services/bingdict.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/modules/services/bingdict.ts b/src/modules/services/bingdict.ts index d46b19a9..633ac999 100644 --- a/src/modules/services/bingdict.ts +++ b/src/modules/services/bingdict.ts @@ -16,7 +16,9 @@ export default async function (data) { const phoneticText = doc.querySelectorAll(".hd_area .b_primtxt"); data.audio = mp3s.map((a: Element, i: number) => ({ text: phoneticText[i].innerHTML.replace(" ", " "), - url: (a.getAttribute("onclick")?.match(/https?:\/\/\S+\.mp3/g) || [""])[0], + url: (a.getAttribute("data-mp3link")?.match(/https?:\/\/\S+\.mp3/g) || [ + "", + ])[0], })); try {