feat: 点击下一首自动播放,优化 https问题

This commit is contained in:
alger
2025-05-17 20:10:07 +08:00
parent 8c6b69e762
commit 2379b2c9cc
2 changed files with 2 additions and 5 deletions
+1 -5
View File
@@ -806,10 +806,6 @@ export const usePlayerStore = defineStore('player', () => {
return;
}
// 在切换前保存当前播放状态
const shouldPlayNext = play.value;
console.log('切换到下一首,当前播放状态:', shouldPlayNext ? '播放' : '暂停');
// 保存当前索引,用于错误恢复
const currentIndex = playListIndex.value;
let nowPlayListIndex: number;
@@ -841,7 +837,7 @@ export const usePlayerStore = defineStore('player', () => {
// 尝试播放,最多尝试maxRetries次
while (!success && retryCount < maxRetries) {
success = await handlePlayMusic(nextSong, shouldPlayNext);
success = await handlePlayMusic(nextSong, true);
if (!success) {
retryCount++;