1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-02-03 06:02:51 +08:00

new video-id extraction to deal with recent site changes

This commit is contained in:
mr-sketchy 2017-09-24 11:15:21 -07:00
parent 9fc41bcb6b
commit 0250841acf

View File

@ -126,6 +126,7 @@ class XHamsterIE(InfoExtractor):
video_url = self._search_regex(
[r'''file\s*:\s*(?P<q>["'])(?P<mp4>.+?)(?P=q)''',
r'''<a\s+href=(?P<q>["'])(?P<mp4>.+?)(?P=q)\s+class=["']mp4Thumb''',
r'''<a\s+class=["']download["']\s+id=["']video_download["']\s+href=(?P<q>\S+?)(?P<mp4>.+?)["']''',
r'''<video[^>]+file=(?P<q>["'])(?P<mp4>.+?)(?P=q)[^>]*>'''],
webpage, 'video url', group='mp4', default=None)
if video_url and video_url not in format_urls: