[peertube] Detect embed URLs in generic extraction (closes #21666)
authorSergey M․ <dstftw@gmail.com>
Fri, 5 Jul 2019 17:42:54 +0000 (00:42 +0700)
committerSergey M․ <dstftw@gmail.com>
Fri, 5 Jul 2019 17:50:56 +0000 (00:50 +0700)
youtube_dl/extractor/peertube.py

index e03c3d1d3d61ec2fd981776fba2775464b9658d1..b50543e329f983a9fe06c0bda9c457bb2aa337b6 100644 (file)
@@ -168,7 +168,7 @@ class PeerTubeIE(InfoExtractor):
     @staticmethod
     def _extract_peertube_url(webpage, source_url):
         mobj = re.match(
-            r'https?://(?P<host>[^/]+)/videos/watch/(?P<id>%s)'
+            r'https?://(?P<host>[^/]+)/videos/(?:watch|embed)/(?P<id>%s)'
             % PeerTubeIE._UUID_RE, source_url)
         if mobj and any(p in webpage for p in (
                 '<title>PeerTube<',