1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-02 17:22:31 +01:00

[youtube] Bugfix in _extract_ytcfg

This commit is contained in:
pukkandan 2021-04-21 10:37:24 +05:30
parent c32b0aab8a
commit 8c54a3051d
No known key found for this signature in database
GPG Key ID: 0F00D95A001F4698

View File

@ -356,6 +356,8 @@ def _extract_account_syncid(data):
return data.get('DELEGATED_SESSION_ID')
def _extract_ytcfg(self, video_id, webpage):
if not webpage:
return {}
return self._parse_json(
self._search_regex(
r'ytcfg\.set\s*\(\s*({.+?})\s*\)\s*;', webpage, 'ytcfg',