Also remove 'once' event listeners when destroying (they may still be waiting)

This commit is contained in:
Albin Larsson
2018-06-12 19:43:08 +02:00
parent 53933dff7e
commit 927326f715
4 changed files with 6 additions and 6 deletions

View File

@ -975,7 +975,7 @@ class Plyr {
* @param {function} callback - Callback for when event occurs
*/
once(event, callback) {
once(this.elements.container, event, callback);
once.call(this, this.elements.container, event, callback);
}
/**
* Remove event listeners