mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-21 20:46:36 -05:00
Merge pull request #2464 from rzhxeo/xhamster
[XHamsterIE] Make hd video search more robust
This commit is contained in:
commit
2648c436f3
1 changed files with 1 additions and 0 deletions
|
@ -103,6 +103,7 @@ def is_hd(webpage):
|
||||||
}]
|
}]
|
||||||
|
|
||||||
if not hd:
|
if not hd:
|
||||||
|
mrss_url = self._search_regex(r'<link rel="canonical" href="([^"]+)', webpage, 'mrss_url')
|
||||||
webpage = self._download_webpage(mrss_url + '?hd', video_id, note='Downloading HD webpage')
|
webpage = self._download_webpage(mrss_url + '?hd', video_id, note='Downloading HD webpage')
|
||||||
if is_hd(webpage):
|
if is_hd(webpage):
|
||||||
video_url = extract_video_url(webpage)
|
video_url = extract_video_url(webpage)
|
||||||
|
|
Loading…
Reference in a new issue