fix. 添加选择条件以防止多次调用接口

This commit is contained in:
IamFurina 2025-03-15 14:16:01 +08:00 committed by GitHub
parent b725db1380
commit 712c26d3da
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -240,7 +240,7 @@ async function consturctServer(moduleDefs) {
})
console.log('[OK]', decode(req.originalUrl))
if (req.baseUrl === '/song/url/v1' || req.baseUrl === '/song/url') {
if (song.freeTrialInfo !== null && (req.baseUrl === '/song/url/v1' || req.baseUrl === '/song/url')) {
const song = moduleResponse['body']['data'][0]
if (!song.url || [1, 4].includes(song.fee)) {
const match = require('@unblockneteasemusic/server')