From ea3f36dbc97896df0963f0503dea3f22bfa82968 Mon Sep 17 00:00:00 2001 From: lyswhut Date: Sun, 16 Apr 2023 13:31:01 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0kg=E8=8E=B7=E5=8F=96=E6=AD=8C?= =?UTF-8?q?=E5=8D=95gid=E6=8E=A5=E5=8F=A3=20&=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E6=AD=8C=E5=8D=95=E4=BB=8B=E7=BB=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/musicSdk/kg/songList.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/utils/musicSdk/kg/songList.js b/src/utils/musicSdk/kg/songList.js index 671abd1..9c6b61e 100644 --- a/src/utils/musicSdk/kg/songList.js +++ b/src/utils/musicSdk/kg/songList.js @@ -58,14 +58,14 @@ export default { listDetailLink: /^.+\/(\d+)\.html(?:\?.*|&.*$|#.*$|$)/, }, async getGlobalSpecialId(specialId) { - return httpFetch(`https://m.kugou.com/plist/list/${specialId}/?json=true`, { + return httpFetch(`http://mobilecdnbj.kugou.com/api/v5/special/info?specialid=${specialId}`, { headers: { 'User-Agent': 'Mozilla/5.0 (Linux; Android 10; HLK-AL00) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.102 Mobile Safari/537.36 EdgA/104.0.1293.70', }, }).promise.then(({ body }) => { // console.log(body) - if (!body.info.list.global_specialid) Promise.reject(new Error('Failed to get global collection id.')) - return body.info.list.global_specialid + if (!body.data.global_specialid) Promise.reject(new Error('Failed to get global collection id.')) + return body.data.global_specialid }) }, // async getListInfoBySpecialId(special_id, retry = 0) { @@ -451,9 +451,9 @@ export default { info: { name: info.specialname, img: info.imgurl && info.imgurl.replace('{size}', 240), - // desc: body.result.info.list_desc, + desc: info.intro, author: info.nickname, - // play_count: this.formatPlayCount(info.count), + play_count: this.formatPlayCount(info.playcount), }, } },