aboutsummaryrefslogtreecommitdiffstats
path: root/hypervideo_dl/extractor/theplatform.py
diff options
context:
space:
mode:
authorJesús <heckyel@hyperbola.info>2021-10-18 15:24:21 -0500
committerJesús <heckyel@hyperbola.info>2021-10-18 15:24:21 -0500
commit5122028a4bcac4ae577ef7fbd55ccad5cb34ef5e (patch)
tree65209bc739db35e31f1c9b5b868eb5df4fe12ae3 /hypervideo_dl/extractor/theplatform.py
parent27fe903c511691c078942bef5ee9a05a43b15c8f (diff)
downloadhypervideo-5122028a4bcac4ae577ef7fbd55ccad5cb34ef5e.tar.lz
hypervideo-5122028a4bcac4ae577ef7fbd55ccad5cb34ef5e.tar.xz
hypervideo-5122028a4bcac4ae577ef7fbd55ccad5cb34ef5e.zip
update from upstream
Diffstat (limited to 'hypervideo_dl/extractor/theplatform.py')
-rw-r--r--hypervideo_dl/extractor/theplatform.py13
1 files changed, 5 insertions, 8 deletions
diff --git a/hypervideo_dl/extractor/theplatform.py b/hypervideo_dl/extractor/theplatform.py
index adfe11e..c2729f1 100644
--- a/hypervideo_dl/extractor/theplatform.py
+++ b/hypervideo_dl/extractor/theplatform.py
@@ -10,15 +10,12 @@ import hashlib
from .once import OnceIE
from .adobepass import AdobePassIE
-from ..compat import (
- compat_parse_qs,
- compat_urllib_parse_urlparse,
-)
from ..utils import (
determine_ext,
ExtractorError,
float_or_none,
int_or_none,
+ parse_qs,
sanitized_Request,
unsmuggle_url,
update_url_query,
@@ -238,7 +235,7 @@ class ThePlatformIE(ThePlatformBaseIE, AdobePassIE):
'countries': smuggled_data.get('geo_countries'),
})
- mobj = re.match(self._VALID_URL, url)
+ mobj = self._match_valid_url(url)
provider_id = mobj.group('provider_id')
video_id = mobj.group('id')
@@ -250,7 +247,7 @@ class ThePlatformIE(ThePlatformBaseIE, AdobePassIE):
path += mobj.group('media')
path += video_id
- qs_dict = compat_parse_qs(compat_urllib_parse_urlparse(url).query)
+ qs_dict = parse_qs(url)
if 'guid' in qs_dict:
webpage = self._download_webpage(url, video_id)
scripts = re.findall(r'<script[^>]+src="([^"]+)"', webpage)
@@ -359,7 +356,7 @@ class ThePlatformFeedIE(ThePlatformBaseIE):
if first_video_id is None:
first_video_id = cur_video_id
duration = float_or_none(item.get('plfile$duration'))
- file_asset_types = item.get('plfile$assetTypes') or compat_parse_qs(compat_urllib_parse_urlparse(smil_url).query)['assetTypes']
+ file_asset_types = item.get('plfile$assetTypes') or parse_qs(smil_url)['assetTypes']
for asset_type in file_asset_types:
if asset_type in asset_types:
continue
@@ -404,7 +401,7 @@ class ThePlatformFeedIE(ThePlatformBaseIE):
return ret
def _real_extract(self, url):
- mobj = re.match(self._VALID_URL, url)
+ mobj = self._match_valid_url(url)
video_id = mobj.group('id')
provider_id = mobj.group('provider_id')