[extractor/generic] Extend dailymotion embed regex
authorSergey M․ <dstftw@gmail.com>
Tue, 19 Jan 2016 15:20:45 +0000 (21:20 +0600)
committerSergey M․ <dstftw@gmail.com>
Tue, 19 Jan 2016 15:20:45 +0000 (21:20 +0600)
youtube_dl/extractor/generic.py

index b3f8efc80ba5f6ecaf99f528832f5ad4db8b11c3..0baa17e8d80024c1c2f6fed25230a0c99469247b 100644 (file)
@@ -1402,7 +1402,7 @@ class GenericIE(InfoExtractor):
 
         # Look for embedded Dailymotion player
         matches = re.findall(
-            r'<iframe[^>]+?src=(["\'])(?P<url>(?:https?:)?//(?:www\.)?dailymotion\.com/embed/video/.+?)\1', webpage)
+            r'<(?:embed|iframe)[^>]+?src=(["\'])(?P<url>(?:https?:)?//(?:www\.)?dailymotion\.com/(?:embed|swf)/video/.+?)\1', webpage)
         if matches:
             return _playlist_from_matches(
                 matches, lambda m: unescapeHTML(m[1]))