fix: 修复下载歌曲异常 #43

This commit is contained in:
imsyy
2023-05-29 17:48:21 +08:00
parent c30263b019
commit 73798ba196

View File

@@ -96,7 +96,7 @@ const toSongDownload = (id, br, name) => {
if (res.data.url) {
const type = res.data.type.toLowerCase();
const songName = name ? name : t("general.name.unknownSong");
fetch(res.data.url)
fetch(res.data.url.replace(/^http:/, "https:"))
.then((response) => response.blob())
.then((blob) => {
const url = window.URL.createObjectURL(blob);