From: Sergey M․ Date: Fri, 8 Jan 2016 18:21:57 +0000 (+0600) Subject: [xhamster] Fix upload date extraction X-Git-Url: http://git.oshgnacknak.de/?a=commitdiff_plain;h=4763b624a6655bc2333157031c73858f6b918f61;p=youtube-dl [xhamster] Fix upload date extraction --- diff --git a/youtube_dl/extractor/xhamster.py b/youtube_dl/extractor/xhamster.py index 97355d17f..560c38e26 100644 --- a/youtube_dl/extractor/xhamster.py +++ b/youtube_dl/extractor/xhamster.py @@ -72,10 +72,9 @@ class XHamsterIE(InfoExtractor): mobj = re.search(r'Description: ([^<]+)', webpage) description = mobj.group(1) if mobj else None - upload_date = self._html_search_regex(r'hint=\'(\d{4}-\d{2}-\d{2}) \d{2}:\d{2}:\d{2} [A-Z]{3,4}\'', - webpage, 'upload date', fatal=False) - if upload_date: - upload_date = unified_strdate(upload_date) + upload_date = unified_strdate(self._search_regex( + r'hint=["\'](\d{4}-\d{2}-\d{2}) \d{2}:\d{2}:\d{2} [A-Z]{3,4}', + webpage, 'upload date', fatal=False)) uploader = self._html_search_regex( r"]+>(?P[^<]+)",