]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[anysex] Fix extraction
authorSergey M․ <dstftw@gmail.com>
Sat, 27 Sep 2014 15:29:27 +0000 (22:29 +0700)
committerSergey M․ <dstftw@gmail.com>
Sat, 27 Sep 2014 15:29:27 +0000 (22:29 +0700)
youtube_dl/extractor/anysex.py

index bc64423a3f69cd3407701e7b02df333a4f7e628c..ad86d6e58a0d6ac739af711745e73787cc83289e 100644 (file)
@@ -35,7 +35,7 @@ class AnySexIE(InfoExtractor):
 
         title = self._html_search_regex(r'<title>(.*?)</title>', webpage, 'title')
         description = self._html_search_regex(
-            r'<div class="description">([^<]+)</div>', webpage, 'description', fatal=False)
+            r'<div class="description"[^>]*>([^<]+)</div>', webpage, 'description', fatal=False)
         thumbnail = self._html_search_regex(
             r'preview_url\s*:\s*\'(.*?)\'', webpage, 'thumbnail', fatal=False)
 
@@ -43,7 +43,7 @@ class AnySexIE(InfoExtractor):
             r'<a href="http://anysex\.com/categories/[^"]+" title="[^"]*">([^<]+)</a>', webpage)
 
         duration = parse_duration(self._search_regex(
-            r'<b>Duration:</b> (\d+:\d+)', webpage, 'duration', fatal=False))
+            r'<b>Duration:</b> (?:<q itemprop="duration">)?(\d+:\d+)', webpage, 'duration', fatal=False))
         view_count = int_or_none(self._html_search_regex(
             r'<b>Views:</b> (\d+)', webpage, 'view count', fatal=False))