[vk] Detect vimeo embeds (Closes #7021)
authorSergey M․ <dstftw@gmail.com>
Wed, 30 Sep 2015 16:12:52 +0000 (22:12 +0600)
committerSergey M․ <dstftw@gmail.com>
Wed, 30 Sep 2015 16:12:52 +0000 (22:12 +0600)
youtube_dl/extractor/vk.py

index c30c5a8e524324a29d7c4a2dad49d5b9d50dda30..765e9e6fd4088f10b7fdd01652e8c62f2dcd05cd 100644 (file)
@@ -17,6 +17,7 @@ from ..utils import (
     unescapeHTML,
     unified_strdate,
 )
+from .vimeo import VimeoIE
 
 
 class VKIE(InfoExtractor):
@@ -249,6 +250,10 @@ class VKIE(InfoExtractor):
         if youtube_url:
             return self.url_result(youtube_url, 'Youtube')
 
+        vimeo_url = VimeoIE._extract_vimeo_url(url, info_page)
+        if vimeo_url is not None:
+            return self.url_result(vimeo_url)
+
         m_rutube = re.search(
             r'\ssrc="((?:https?:)?//rutube\.ru\\?/video\\?/embed(?:.*?))\\?"', info_page)
         if m_rutube is not None: