aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/source.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/js/source.js')
-rw-r--r--src/js/source.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/js/source.js b/src/js/source.js
index 4e3f9186..e9a2938e 100644
--- a/src/js/source.js
+++ b/src/js/source.js
@@ -2,12 +2,12 @@
// Plyr source update
// ==========================================================================
-import { providers } from './types';
-import utils from './utils';
import html5 from './html5';
import media from './media';
-import ui from './ui';
import support from './support';
+import { providers } from './types';
+import ui from './ui';
+import utils from './utils';
const source = {
// Add elements to HTML5 media (source, tracks, etc)
@@ -94,8 +94,8 @@ const source = {
if (this.config.autoplay) {
this.media.setAttribute('autoplay', '');
}
- if ('poster' in input) {
- this.media.setAttribute('poster', input.poster);
+ if (!utils.is.empty(input.poster)) {
+ this.poster = input.poster;
}
if (this.config.loop.active) {
this.media.setAttribute('loop', '');