This repository has been archived by the owner on Apr 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 15.8k
song_url
接口返回 Buffer 而不是 string 或者 object
#1240
Comments
我将尝试跟踪,解决这个问题。我先测试一下是不是 node 的问题。 |
P.S |
@Binaryify 做了个修复: 由于 NeteaseCloudMusicApi/util/request.js Line 173 in 97bd7fe
} catch (e) {
// console.log(e)
answer.body = body
answer.status = res.status
} 修改为: } catch (e) {
// console.log(e)
try {
answer.body = JSON.parse(body.toString())
} catch (err) {
// console.log(err)
// can't decrypt and can't parse directly
answer.body = body
}
answer.status = res.status
} 即可。我已经提交了一个 PR 修复此问题。 |
Merged
#1241 解决了该问题 |
好了 |
好 |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
环境
系统/平台: Windows 10 21H1(WSL, Ubuntu 20.04 LTS) & CentOS 7 & Ubuntu Server 20.04 LTS
nodejs 版本: 16.2.0
API版本: 4.0.12
出现问题
song_url
接口返回 Buffer 而不是 string 或者 object重现步骤
返回结果:
期待效果
修复该问题
The text was updated successfully, but these errors were encountered: