1
0
mirror of https://codeberg.org/polarisfm/youtube-dl synced 2024-11-22 16:44:32 +01:00

[tbs] fix typo

This commit is contained in:
Remita Amine 2017-12-12 18:16:45 +01:00
parent 6b2d8c9182
commit 15960255fe

View File

@ -36,8 +36,7 @@ class TBSIE(TurnerBaseIE):
}] }]
def _real_extract(self, url): def _real_extract(self, url):
domain, display_id = re.match(self._VALID_URL, url).groups() site, display_id = re.match(self._VALID_URL, url).groups()
site = domain[:3]
webpage = self._download_webpage(url, display_id) webpage = self._download_webpage(url, display_id)
video_data = self._parse_json(self._search_regex( video_data = self._parse_json(self._search_regex(
r'<script[^>]+?data-drupal-selector="drupal-settings-json"[^>]*?>({.+?})</script>', r'<script[^>]+?data-drupal-selector="drupal-settings-json"[^>]*?>({.+?})</script>',
@ -62,7 +61,7 @@ class TBSIE(TurnerBaseIE):
'http://www.%s.com/service/token_spe' % site, 'http://www.%s.com/service/token_spe' % site,
m3u8_url, media_id, { m3u8_url, media_id, {
'url': url, 'url': url,
'site_name': site.upper(), 'site_name': site[:3].upper(),
'auth_required': video_data.get('authRequired') == '1', 'auth_required': video_data.get('authRequired') == '1',
}) })
formats.extend(self._extract_m3u8_formats( formats.extend(self._extract_m3u8_formats(