mirror of
https://github.com/Jerryplusy/rc-plugin.git
synced 2025-10-14 16:19:18 +00:00
🐞 fix: 修复 bodian 无法发送的问题
This commit is contained in:
parent
df37390108
commit
7ae76b6143
@ -21,19 +21,15 @@ async function getBodianAudio(id, path) {
|
|||||||
"Cache-Control": "no-cache",
|
"Cache-Control": "no-cache",
|
||||||
channel: "appstore",
|
channel: "appstore",
|
||||||
};
|
};
|
||||||
return await axios
|
const resp = await axios.get(API, {
|
||||||
.get(API, {
|
|
||||||
headers,
|
headers,
|
||||||
})
|
});
|
||||||
.then(async resp => {
|
|
||||||
const respJson = resp.data;
|
const respJson = resp.data;
|
||||||
const audioUrl = respJson.data.audioUrl;
|
const audioUrl = respJson.data.audioUrl;
|
||||||
await downloadAudio(audioUrl, path)
|
return await downloadAudio(audioUrl, path)
|
||||||
.catch(err => {
|
.catch(err => {
|
||||||
console.error(`下载音乐失败,错误信息为: ${ err.message }`);
|
console.error(`下载音乐失败,错误信息为: ${ err.message }`);
|
||||||
});
|
});
|
||||||
return respJson;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user