🐞 fix: 修复netease无法解析歌曲问题

This commit is contained in:
zhiyu1998 2024-05-30 22:10:25 +08:00
parent 0954d6f1ca
commit 560ea274f4

View File

@ -1028,7 +1028,8 @@ export class tools extends plugin {
}
// 动态判断后缀名
const extensionPattern = /\.([a-zA-Z0-9]+)$/;
const musicExt = url.match(extensionPattern);
const musicExt = url.match(extensionPattern)?.[0].replace("\.", "");
logger.info(musicExt);
// 下载音乐
downloadAudio(url, this.getCurDownloadPath(e), title, 'follow', musicExt).then(async path => {
// 发送语音