mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-10-01 14:51:25 +02:00
Compare commits
2 Commits
924eaf334e
...
5c758e9580
Author | SHA1 | Date | |
---|---|---|---|
|
5c758e9580 | ||
|
6d40d2137f |
|
@ -152,15 +152,13 @@ class ERRJupiterIE(InfoExtractor):
|
||||||
|
|
||||||
def _real_extract(self, url):
|
def _real_extract(self, url):
|
||||||
video_id = self._match_id(url)
|
video_id = self._match_id(url)
|
||||||
data = try_call(lambda: self._download_json(
|
data = self._download_json(
|
||||||
'https://services.err.ee/api/v2/vodContent/getContentPageData', video_id,
|
'https://services.err.ee/api/v2/vodContent/getContentPageData', video_id,
|
||||||
query={'contentId': video_id})['data']['mainContent'])
|
query={'contentId': video_id})['data']['mainContent']
|
||||||
if not data:
|
|
||||||
raise ExtractorError('Failed to get video data', expected=True)
|
|
||||||
|
|
||||||
media_data = traverse_obj(data, ('medias', ..., {dict}), get_all=False)
|
media_data = traverse_obj(data, ('medias', ..., {dict}), get_all=False)
|
||||||
if traverse_obj(media_data, ('restrictions', 'drm', {bool})):
|
if traverse_obj(media_data, ('restrictions', 'drm', {bool})):
|
||||||
self.raise_no_formats('This video is DRM protected', expected=True)
|
self.report_drm(video_id)
|
||||||
|
|
||||||
formats, subtitles = [], {}
|
formats, subtitles = [], {}
|
||||||
for url in set(traverse_obj(media_data, ('src', ('hls', 'hls2', 'hlsNew'), {url_or_none}))):
|
for url in set(traverse_obj(media_data, ('src', ('hls', 'hls2', 'hlsNew'), {url_or_none}))):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user