Completed buildPlayer method for youtubeEmbedHandler
This commit is contained in:
parent
1344756449
commit
1b0caa5e02
6 changed files with 43 additions and 19 deletions
|
|
@ -163,7 +163,7 @@ class channel{
|
|||
}
|
||||
|
||||
//Youtube iframe-embed API load handler
|
||||
function onYoutubeIframeAPIReady(){
|
||||
function onYouTubeIframeAPIReady(){
|
||||
//Set embed api to true
|
||||
client.ytEmbedAPILoaded = true;
|
||||
|
||||
|
|
@ -171,7 +171,7 @@ function onYoutubeIframeAPIReady(){
|
|||
const nowPlaying = client.player.mediaHandler.nowPlaying;
|
||||
|
||||
//If we're playing a youtube video and the official embeds are enabled
|
||||
if(nowPlaying.type == 'yt' && localStorage.get('ytPlayerType') == "embed"){
|
||||
if(nowPlaying.type == 'yt' && localStorage.getItem('ytPlayerType') == "embed"){
|
||||
//Restart the video now that the embed api has loaded
|
||||
client.player.start({media: nowPlaying});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue