You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(youtube-player): invalid URL when playlist is passed in without videoId (#31403)
* Fix null issue in url youtube url when running a playlist with no videoId
When playing a playlist via playerVars.list = [playlistId] we dont have a videoId available yet. Plus we don't need one, Youtube will start at the first video of the playlist by default.
By injecting an undefined videoId in the YT Player constructur, we end up with null value in the iframe url (`ps://www.youtube.com/embed/null?cc_load_policy=1&enablejsapi=1&controls=1&showinfo=0&rel=0&listType=playlist&list=PLxf07yK_HAvdwhW-L0X3uP5aMe6eEt50v`) which is causing an Invalid Video Id error for consumers.
* Update youtube-player.ts
apply YT.PlayerOptions to params
* Update youtube-player.ts
fix formatting
* Update youtube-player.spec.ts
fix unit test
* Update youtube-player.ts
Fix formatting
(cherry picked from commit 2c87ec3)
0 commit comments