[empflix] Extract thumbnail
authorSergey M․ <dstftw@gmail.com>
Tue, 26 Aug 2014 13:10:36 +0000 (20:10 +0700)
committerSergey M․ <dstftw@gmail.com>
Tue, 26 Aug 2014 13:10:36 +0000 (20:10 +0700)
youtube_dl/extractor/empflix.py

index 1290cd9f7028aace78fc104cceb76b33da6752ca..3c2289e5710d78b9f934ee2e578d9539d3cc267a 100644 (file)
@@ -47,10 +47,14 @@ class EmpflixIE(InfoExtractor):
                 r'<item>\s*<res>([^>]+)</res>\s*<videoLink>([^<]+)</videoLink>\s*</item>', cfg_xml)
         ]
 
+        thumbnail = self._html_search_regex(
+            r'<startThumb>([^<]+)</startThumb>', cfg_xml, 'thumbnail', fatal=False)
+
         return {
             'id': video_id,
             'title': video_title,
             'description': video_description,
+            'thumbnail': thumbnail,
             'formats': formats,
             'age_limit': age_limit,
         }