0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-27 03:03:01 +00:00

[bbc] Improve data-playable regex

This commit is contained in:
Sergey M․ 2015-10-10 23:20:30 +06:00
parent c936d8cc7b
commit b1ec70e4a9

View file

@ -739,7 +739,8 @@ def _real_extract(self, url):
# http://www.bbc.com/news/world-us-canada-34473351)
data_playable = self._parse_json(
unescapeHTML(self._search_regex(
r'data-playable="({.+?})"', webpage, 'data playable', default='{}')),
r'data-playable=(["\'])(?P<json>{.+?})\1', webpage,
'data playable', default='{}', group='json')),
programme_id, fatal=False)
if data_playable:
# data-playable has video vpid in settings.playlistObject.items (e.g.