1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-02 17:22:31 +01:00
This commit is contained in:
pukkandan 2022-08-15 01:53:42 +05:30
parent 6440c45ff3
commit 48732becfe
No known key found for this signature in database
GPG Key ID: 7EEE9E1E817D0A39

View File

@ -238,8 +238,8 @@ def _extract_ondemand(self, ondemand_id):
return info_dict
def _real_extract(self, url):
vid1, vid2 = self._match_valid_url(url).group('vid1', 'vid2')
return getattr(self, f'_extract_{self._TYPE}')(vid1 or vid2)
video_id, record_id = self._match_valid_url(url).groups()
return self._extract_video(video_id, record_id)
def _make_valid_url(host):
@ -258,6 +258,10 @@ def _create_valid_url(match, qs, base_re=None):
{match_base}
)'''
def _real_extract(self, url):
vid1, vid2 = self._match_valid_url(url).group('vid1', 'vid2')
return getattr(self, f'_extract_{self._TYPE}')(vid1 or vid2)
class ZattooIE(ZattooBaseIE):
_VALID_URL = ZattooBaseIE._create_valid_url(r'\d+', 'program', '(?:program|watch)/[^/]+')