diff --git a/web/src/js/modules/popup.js b/web/src/js/modules/popup.js index ba714c68..b3d98b21 100644 --- a/web/src/js/modules/popup.js +++ b/web/src/js/modules/popup.js @@ -4,7 +4,10 @@ var selectedWeekdays = {}; $(document).ready(function () { $(".js-video-modal").each(function(){ const $this = $(this); - const url = $this.data('video-url'); + const url = $this.data('videoUrl'); + if(! url){ + return; + } let data; let videoId; let channel; @@ -22,7 +25,8 @@ $(document).ready(function () { channel = 'vimeo'; videoId = split[split.length - 1]; } - $this.data('videoId', videoId); + $this.attr('data-video-id', videoId); + $this.attr('data-video-url', ''); $this.modalVideo({ channel }); });