From 85d4b194bcddae279dea7d67ea30562ddc0e8bef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=A7=89?= Date: Wed, 4 Oct 2023 07:10:49 +0800 Subject: [PATCH] =?UTF-8?q?=E6=92=AD=E6=94=BE=E7=8A=B6=E6=80=81=E6=A3=80?= =?UTF-8?q?=E6=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/music.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/public/music.js b/public/music.js index 433312a..f69b4c5 100644 --- a/public/music.js +++ b/public/music.js @@ -157,9 +157,9 @@ export default class MusicList { this.event.onplay(item) } async stop() { - //if (!this.audio.paused) { - // this.audio.pause() - //} + if (this.audio.paused) { + return console.error('暂停播放:音乐播放器不是播放状态!') + } this.audio.pause() this.audio.src = '' this.event.onstop(this.playing)