diff --git a/assets/js/invidious_iframe_api.js b/assets/js/invidious_iframe_api.js index e85a2a53..4690048e 100644 --- a/assets/js/invidious_iframe_api.js +++ b/assets/js/invidious_iframe_api.js @@ -310,12 +310,7 @@ class invidious_embed{ search_params.append('widgetid',invidious_embed.widgetid); this.widgetid = invidious_embed.widgetid; invidious_embed.widgetid++; - if(autoplay){ - search_params.append('autoplay',1); - } - else{ - search_params.append('autoplay',0); - } + search_params.append('autoplay', Number(autoplay)); if(this.option_playerVars!==undefined){ for(var x in this.option_playerVars){ if(x!=='autoplay'&&x!=='start'&&x!=='end'){ @@ -361,7 +356,7 @@ class invidious_embed{ } async getVideoEmbedCode(){ var title = await this.getVideoTitle(); - return ''; + return ''; } getCurrentTime(){ return this.promise_send_event('getcurrenttime');