[pulsevideo] unduplicating formats
This commit is contained in:
parent
98a2f0c8fe
commit
d506825a5c
|
@ -55,13 +55,13 @@ class PulseVideoIE(InfoExtractor):
|
||||||
|
|
||||||
def _extract_from_id(self, video_id, webpage=None):
|
def _extract_from_id(self, video_id, webpage=None):
|
||||||
response = self._download_json(
|
response = self._download_json(
|
||||||
'http://qi.ckm.onetapi.pl/', video_id,
|
'https://player-api.dreamlab.pl/', video_id,
|
||||||
query={
|
query={
|
||||||
'body[id]': video_id,
|
'body[id]': video_id,
|
||||||
'body[jsonrpc]': '2.0',
|
'body[jsonrpc]': '2.0',
|
||||||
'body[method]': 'get_asset_detail',
|
'body[method]': 'get_asset_detail',
|
||||||
'body[params][ID_Publikacji]': video_id,
|
'body[params][ID_Publikacji]': video_id,
|
||||||
'body[params][Service]': 'www.onet.pl',
|
'body[params][version]': '2.0',
|
||||||
'content-type': 'application/jsonp',
|
'content-type': 'application/jsonp',
|
||||||
'x-onet-app': 'player.front.onetapi.pl',
|
'x-onet-app': 'player.front.onetapi.pl',
|
||||||
})
|
})
|
||||||
|
@ -84,6 +84,10 @@ class PulseVideoIE(InfoExtractor):
|
||||||
video_url = f.get('url')
|
video_url = f.get('url')
|
||||||
if not video_url:
|
if not video_url:
|
||||||
continue
|
continue
|
||||||
|
# UHD formats are bullshit, they are just duplicates
|
||||||
|
# https://git.sakamoto.pl/laudompat/haruhi-dl/-/issues/45
|
||||||
|
if format_id.endswith('-uhd') and formats_dict.get(format_id[:-len('-uhd')]):
|
||||||
|
continue
|
||||||
ext = determine_ext(video_url)
|
ext = determine_ext(video_url)
|
||||||
if format_id.startswith('ism'):
|
if format_id.startswith('ism'):
|
||||||
formats.extend(self._extract_ism_formats(
|
formats.extend(self._extract_ism_formats(
|
||||||
|
|
Loading…
Reference in a new issue