0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-23 02:25:11 +00:00

[youtube] More explicit player config JSON extraction (fixes #7468)

This commit is contained in:
Lukáš Lalinský 2015-11-22 13:14:35 +01:00
parent 0c176d7bde
commit 3cfd000849

View file

@ -1074,7 +1074,7 @@ def add_dash_mpd(video_info):
age_gate = False
video_info = None
# Try looking directly into the video webpage
mobj = re.search(r';ytplayer\.config\s*=\s*({.*?});', video_webpage)
mobj = re.search(r';ytplayer\.config\s*=\s*({.*?});ytplayer', video_webpage)
if mobj:
json_code = uppercase_escape(mobj.group(1))
ytplayer_config = json.loads(json_code)