aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/listeners.js
diff options
context:
space:
mode:
authorAlbin Larsson <mail@albinlarsson.com>2018-06-12 19:43:08 +0200
committerAlbin Larsson <mail@albinlarsson.com>2018-06-12 20:00:41 +0200
commit927326f715132d56c79de70e9b871594514caa2f (patch)
tree8233bd7d1a5c239016ac594df316d9418c027992 /src/js/listeners.js
parent53933dff7eaa8074e57cccc7cab18d5be6c83fc4 (diff)
downloadplyr-927326f715132d56c79de70e9b871594514caa2f.tar.lz
plyr-927326f715132d56c79de70e9b871594514caa2f.tar.xz
plyr-927326f715132d56c79de70e9b871594514caa2f.zip
Also remove 'once' event listeners when destroying (they may still be waiting)
Diffstat (limited to 'src/js/listeners.js')
-rw-r--r--src/js/listeners.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/js/listeners.js b/src/js/listeners.js
index 0597e9d3..283bd4a2 100644
--- a/src/js/listeners.js
+++ b/src/js/listeners.js
@@ -210,7 +210,7 @@ class Listeners {
toggleListener.call(this.player, document.body, 'click', this.toggleMenu, toggle);
// Detect touch by events
- once(document.body, 'touchstart', this.firstTouch);
+ once.call(this.player, document.body, 'touchstart', this.firstTouch);
}
// Container listeners