aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets
diff options
context:
space:
mode:
authorkontrollanten <6680299+kontrollanten@users.noreply.github.com>2020-12-06 22:33:27 +0100
committerChocobozzz <chocobozzz@cpy.re>2020-12-07 08:59:08 +0100
commitadc1f09c0dbd997f34028c1c82d1c118dc8ead80 (patch)
tree60b44dff857f43655b2dfef2bec125afae041571 /client/src/assets
parent59bc5f7dc09c41181ed89b0b2ac350ac783fd2b5 (diff)
downloadPeerTube-adc1f09c0dbd997f34028c1c82d1c118dc8ead80.tar.gz
PeerTube-adc1f09c0dbd997f34028c1c82d1c118dc8ead80.tar.zst
PeerTube-adc1f09c0dbd997f34028c1c82d1c118dc8ead80.zip
hls-plugin: destroy hls upon third err
According to hls.js docs `hls.destroy()` should be called https://github.com/video-dev/hls.js/blob/master/docs/API.md#final-step-destroying-switching-between-streams
Diffstat (limited to 'client/src/assets')
-rw-r--r--client/src/assets/player/p2p-media-loader/hls-plugin.ts1
1 files changed, 1 insertions, 0 deletions
diff --git a/client/src/assets/player/p2p-media-loader/hls-plugin.ts b/client/src/assets/player/p2p-media-loader/hls-plugin.ts
index cf8cb824d..ca7a341b4 100644
--- a/client/src/assets/player/p2p-media-loader/hls-plugin.ts
+++ b/client/src/assets/player/p2p-media-loader/hls-plugin.ts
@@ -226,6 +226,7 @@ class Html5Hlsjs {
226 226
227 if (this.errorCounts[ Hlsjs.ErrorTypes.MEDIA_ERROR ] > 2) { 227 if (this.errorCounts[ Hlsjs.ErrorTypes.MEDIA_ERROR ] > 2) {
228 console.info('bubbling media error up to VIDEOJS') 228 console.info('bubbling media error up to VIDEOJS')
229 this.hls.destroy()
229 this.tech.error = () => error 230 this.tech.error = () => error
230 this.tech.trigger('error') 231 this.tech.trigger('error')
231 return 232 return