about summary refs log tree commit diff
path: root/youtube_dl/extractor/canalplus.py
diff options
context:
space:
mode:
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2013-11-19 20:43:49 +0100
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2013-11-19 20:44:20 +0100
commit69545c2affb6b126398fd657a12a560a9857dbee (patch)
tree1585c51dbab1fa78b0eeb533f77dd4a368ac3998 /youtube_dl/extractor/canalplus.py
parent495da337ae804fe013738f9d4f23002ead1276c7 (diff)
downloadyoutube-dl-69545c2affb6b126398fd657a12a560a9857dbee.tar.gz
youtube-dl-69545c2affb6b126398fd657a12a560a9857dbee.tar.xz
youtube-dl-69545c2affb6b126398fd657a12a560a9857dbee.zip
[d8] inherit from CanalplusIE
it reuses the same extraction process
Diffstat (limited to 'youtube_dl/extractor/canalplus.py')
-rw-r--r--youtube_dl/extractor/canalplus.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/youtube_dl/extractor/canalplus.py b/youtube_dl/extractor/canalplus.py
index 1db9b24cf..bfa2a8b40 100644
--- a/youtube_dl/extractor/canalplus.py
+++ b/youtube_dl/extractor/canalplus.py
@@ -5,6 +5,7 @@ import xml.etree.ElementTree
 from .common import InfoExtractor
 from ..utils import unified_strdate
 
+
 class CanalplusIE(InfoExtractor):
     _VALID_URL = r'https?://(www\.canalplus\.fr/.*?/(?P<path>.*)|player\.canalplus\.fr/#/(?P<id>\d+))'
     _VIDEO_INFO_TEMPLATE = 'http://service.canal-plus.com/video/rest/getVideosLiees/cplus/%s'
@@ -25,7 +26,7 @@ class CanalplusIE(InfoExtractor):
 
     def _real_extract(self, url):
         mobj = re.match(self._VALID_URL, url)
-        video_id = mobj.group('id')
+        video_id = mobj.groupdict().get('id')
         if video_id is None:
             webpage = self._download_webpage(url, mobj.group('path'))
             video_id = self._search_regex(r'videoId = "(\d+)";', webpage, u'video id')