mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-28 02:51:29 +00:00
[hitbox] Extract formats before metadata
This commit is contained in:
parent
29492f3332
commit
008bee0f50
|
@ -88,10 +88,6 @@ def _extract_metadata(self, url, video_id):
|
||||||
def _real_extract(self, url):
|
def _real_extract(self, url):
|
||||||
video_id = self._match_id(url)
|
video_id = self._match_id(url)
|
||||||
|
|
||||||
metadata = self._extract_metadata(
|
|
||||||
'https://www.hitbox.tv/api/media/video',
|
|
||||||
video_id)
|
|
||||||
|
|
||||||
player_config = self._download_json(
|
player_config = self._download_json(
|
||||||
'https://www.hitbox.tv/api/player/config/video/%s' % video_id,
|
'https://www.hitbox.tv/api/player/config/video/%s' % video_id,
|
||||||
video_id)
|
video_id)
|
||||||
|
@ -123,6 +119,9 @@ def _real_extract(self, url):
|
||||||
})
|
})
|
||||||
self._sort_formats(formats)
|
self._sort_formats(formats)
|
||||||
|
|
||||||
|
metadata = self._extract_metadata(
|
||||||
|
'https://www.hitbox.tv/api/media/video',
|
||||||
|
video_id)
|
||||||
metadata['formats'] = formats
|
metadata['formats'] = formats
|
||||||
|
|
||||||
return metadata
|
return metadata
|
||||||
|
|
Loading…
Reference in a new issue