From 443cdc59fccd35a1c76bf3203d91a3af3df533e3 Mon Sep 17 00:00:00 2001 From: buvta <12312540+buvta@users.noreply.github.com> Date: Sun, 24 Jan 2021 15:34:55 +0800 Subject: [PATCH] =?UTF-8?q?=E5=81=9C=E6=AD=A2=E6=97=B6=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E7=94=9F=E6=88=90hls=E6=92=AD=E6=94=BE=E5=99=A8=EF=BC=8C?= =?UTF-8?q?=E4=BD=BF=E5=81=9C=E6=AD=A2=E6=92=AD=E6=94=BEmp4=E6=97=B6?= =?UTF-8?q?=E2=80=9C=E6=92=AD=E6=94=BE=E2=80=9D=E5=8F=AF=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Play.vue | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/components/Play.vue b/src/components/Play.vue index d2fc0d3..cc59ce7 100644 --- a/src/components/Play.vue +++ b/src/components/Play.vue @@ -619,7 +619,7 @@ export default { this.config.url = '' } try { - this.xg.destroy() + if (this.xg) this.xg.destroy() } catch (err) { } this.xg = null switch (playerType) { @@ -1558,12 +1558,8 @@ export default { this.state.showTimespanSetting = false this.right.list = [] this.getAllhistory() - if (this.playerType !== 'flv') { - this.getPlayer(this.playerType, true) - } else { - this.xg.destroy() - this.getPlayer('hls', true) - } + if (this.playerType === 'flv') this.xg.destroy() + this.getPlayer('hls', true) }, minMaxEvent () { win.on('minimize', () => {