修正移除音乐

This commit is contained in:
2023-10-01 11:28:35 +08:00
parent b68826d590
commit 2ce424dc6b
1 changed files with 1 additions and 2 deletions

View File

@ -121,8 +121,7 @@ export default class MusicList {
}
}
remove(item) {
const el = this.ul.querySelector(`#${item.id}`)
if (el) this.ul.removeChild()
this.ul.querySelector(`#${item.id}`)?.remove()
this.stop() // 停止播放
// 执行回调函数
if (this.EventListeners['remove']) {