aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/canalplus.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2015-07-24 00:21:13 +0600
committerSergey M․ <dstftw@gmail.com>2015-07-24 00:21:13 +0600
commitf3f0b8e4030a07e07385afe6ebb4485ac33e5357 (patch)
treedf5e86c0d1d030abcb6f4892677b7ed242e842ac /youtube_dl/extractor/canalplus.py
parent660f9459dabfc01c7235b4cc57f9c561de522e07 (diff)
[canalplus] Modernize
Diffstat (limited to 'youtube_dl/extractor/canalplus.py')
-rw-r--r--youtube_dl/extractor/canalplus.py12
1 files changed, 4 insertions, 8 deletions
diff --git a/youtube_dl/extractor/canalplus.py b/youtube_dl/extractor/canalplus.py
index 8671236dd..57e0cda2c 100644
--- a/youtube_dl/extractor/canalplus.py
+++ b/youtube_dl/extractor/canalplus.py
@@ -106,15 +106,11 @@ class CanalplusIE(InfoExtractor):
continue
format_id = fmt.tag
if format_id == 'HLS':
- hls_formats = self._extract_m3u8_formats(format_url, video_id, 'mp4')
- for fmt in hls_formats:
- fmt['preference'] = preference(format_id)
- formats.extend(hls_formats)
+ formats.extend(self._extract_m3u8_formats(
+ format_url, video_id, 'mp4', preference=preference(format_id)))
elif format_id == 'HDS':
- hds_formats = self._extract_f4m_formats(format_url + '?hdcore=2.11.3', video_id)
- for fmt in hds_formats:
- fmt['preference'] = preference(format_id)
- formats.extend(hds_formats)
+ formats.extend(self._extract_f4m_formats(
+ format_url + '?hdcore=2.11.3', video_id, preference=preference(format_id)))
else:
formats.append({
'url': format_url,