aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/plyr.js
diff options
context:
space:
mode:
authorDanielh112 <Daniel@sbgsportssoftware.com>2020-08-18 11:15:58 +0100
committerDanielh112 <Daniel@sbgsportssoftware.com>2020-08-18 11:15:58 +0100
commit22af7f16ea4a4269321d29242d63ec23718c92da (patch)
treecde309acc225477e02c90844331c123669aa0e25 /src/js/plyr.js
parent350999575633a44686ee5857ad9853dcd1b55dff (diff)
downloadplyr-22af7f16ea4a4269321d29242d63ec23718c92da.tar.lz
plyr-22af7f16ea4a4269321d29242d63ec23718c92da.tar.xz
plyr-22af7f16ea4a4269321d29242d63ec23718c92da.zip
Network requests are not cancelled after the player is destroyed
Diffstat (limited to 'src/js/plyr.js')
-rw-r--r--src/js/plyr.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/js/plyr.js b/src/js/plyr.js
index 00d33463..6eb337cf 100644
--- a/src/js/plyr.js
+++ b/src/js/plyr.js
@@ -12,6 +12,7 @@ import { getProviderByUrl, providers, types } from './config/types';
import Console from './console';
import controls from './controls';
import Fullscreen from './fullscreen';
+import html5 from './html5';
import Listeners from './listeners';
import media from './media';
import Ads from './plugins/ads';
@@ -1135,6 +1136,9 @@ class Plyr {
// Unbind listeners
unbindListeners.call(this);
+ // Cancel current network requests
+ html5.cancelRequests.call(this);
+
// Replace the container with the original element provided
replaceElement(this.elements.original, this.elements.container);