mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-12-22 14:25:12 +00:00
[zype] fix uplynk id extraction(closes #27956)
This commit is contained in:
parent
ea399a53eb
commit
57f2488bbe
@ -87,11 +87,16 @@ class ZypeIE(InfoExtractor):
|
|||||||
r'(["\'])(?P<url>(?:(?!\1).)+\.m3u8(?:(?!\1).)*)\1',
|
r'(["\'])(?P<url>(?:(?!\1).)+\.m3u8(?:(?!\1).)*)\1',
|
||||||
body, 'm3u8 url', group='url', default=None)
|
body, 'm3u8 url', group='url', default=None)
|
||||||
if not m3u8_url:
|
if not m3u8_url:
|
||||||
source = self._parse_json(self._search_regex(
|
source = self._search_regex(
|
||||||
r'(?s)sources\s*:\s*\[\s*({.+?})\s*\]', body,
|
r'(?s)sources\s*:\s*\[\s*({.+?})\s*\]', body, 'source')
|
||||||
'source'), video_id, js_to_json)
|
|
||||||
if source.get('integration') == 'verizon-media':
|
def get_attr(key):
|
||||||
m3u8_url = 'https://content.uplynk.com/%s.m3u8' % source['id']
|
return self._search_regex(
|
||||||
|
r'\b%s\s*:\s*([\'"])(?P<val>(?:(?!\1).)+)\1' % key,
|
||||||
|
source, key, group='val')
|
||||||
|
|
||||||
|
if get_attr('integration') == 'verizon-media':
|
||||||
|
m3u8_url = 'https://content.uplynk.com/%s.m3u8' % get_attr('id')
|
||||||
formats = self._extract_m3u8_formats(
|
formats = self._extract_m3u8_formats(
|
||||||
m3u8_url, video_id, 'mp4', 'm3u8_native', m3u8_id='hls')
|
m3u8_url, video_id, 'mp4', 'm3u8_native', m3u8_id='hls')
|
||||||
text_tracks = self._search_regex(
|
text_tracks = self._search_regex(
|
||||||
|
Loading…
Reference in New Issue
Block a user