mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-09-27 16:56:30 +02:00
[RedBull] Use og_search_url function
This commit is contained in:
parent
e64fd831b1
commit
0d74df84af
@ -98,13 +98,13 @@ class RedBullTVIE(InfoExtractor):
|
||||
'only_matching': True,
|
||||
}]
|
||||
|
||||
_PAGE_URL_REGEX = r'<meta property="og:url"\s*content="(?P<url>[^"]+)"'
|
||||
|
||||
def _real_extract(self, url):
|
||||
video_id = self._match_id(url)
|
||||
html = self._download_webpage(url, video_id)
|
||||
return self.url_result(
|
||||
re.findall(self._PAGE_URL_REGEX, html)[0], RedBullIE, video_id)
|
||||
try:
|
||||
return self.url_result(self._og_search_url(html), RedBullIE, video_id)
|
||||
except Exception:
|
||||
raise ExtractorError('Failed to extract video URL', expected=True)
|
||||
|
||||
|
||||
class RedBullEmbedIE(RedBullBaseIE):
|
||||
|
Loading…
Reference in New Issue
Block a user