]> gitweb @ CieloNegro.org - youtube-dl.git/commitdiff
[francetv] fix style issues reported by flake8
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Wed, 28 Oct 2015 07:22:04 +0000 (08:22 +0100)
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Wed, 28 Oct 2015 07:22:04 +0000 (08:22 +0100)
* Don't redefine variable in list comprehension
* Line missing indentation

youtube_dl/extractor/francetv.py

index 00a80ba616f4629868f0c7cbe857c135fe279431..8e60cf60f7f7be74c751c037bcae31fb0e1f6510 100644 (file)
@@ -85,9 +85,9 @@ class FranceTVBaseInfoExtractor(InfoExtractor):
 
         subtitles = {}
         subtitles_list = [{
-            'url': subtitle['url'],
-            'ext': subtitle.get('format'),
-        } for subtitle in info.get('subtitles', []) if subtitle.get('url')]
+            'url': subformat['url'],
+            'ext': subformat.get('format'),
+        } for subformat in info.get('subtitles', []) if subformat.get('url')]
         if subtitles_list:
             subtitles['fr'] = subtitles_list
 
@@ -118,7 +118,7 @@ class PluzzIE(FranceTVBaseInfoExtractor):
             'id_video', webpage, 'video id', default=None)
         if not video_id:
             video_id = self._search_regex(
-            r'data-diffusion=["\'](\d+)', webpage, 'video id')
+                r'data-diffusion=["\'](\d+)', webpage, 'video id')
 
         return self._extract_video(video_id, 'Pluzz')