aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/listeners.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/js/listeners.js')
-rw-r--r--src/js/listeners.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/js/listeners.js b/src/js/listeners.js
index 8f95b1a7..7f64375c 100644
--- a/src/js/listeners.js
+++ b/src/js/listeners.js
@@ -221,7 +221,7 @@ const listeners = {
// Handle the media finishing
utils.on(this.media, 'ended', () => {
// Show poster on end
- if (this.type === 'video' && this.config.showPosterOnEnd) {
+ if (this.isHTML5 && this.isVideo && this.config.showPosterOnEnd) {
// Restart
this.restart();
@@ -243,7 +243,7 @@ const listeners = {
utils.on(this.media, 'stalled waiting canplay seeked playing', event => ui.checkLoading.call(this, event));
// Click video
- if (this.supported.ui && this.config.clickToPlay && this.type !== 'audio') {
+ if (this.supported.ui && this.config.clickToPlay && !this.isAudio) {
// Re-fetch the wrapper
const wrapper = utils.getElement.call(this, `.${this.config.classNames.video}`);