]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/olympics.py
[cleanup] Add more ruff rules (#10149)
[yt-dlp.git] / yt_dlp / extractor / olympics.py
index 5507d2fda3730d91931a97cdac8bf173e71abe5b..becf052f6f9a1312731c604f311b6865fe9ecdb1 100644 (file)
@@ -24,9 +24,9 @@ class OlympicsReplayIE(InfoExtractor):
     }]
 
     def _real_extract(self, url):
-        id = self._match_id(url)
+        video_id = self._match_id(url)
 
-        webpage = self._download_webpage(url, id)
+        webpage = self._download_webpage(url, video_id)
         title = self._html_search_meta(('title', 'og:title', 'twitter:title'), webpage)
         uuid = self._html_search_meta('episode_uid', webpage)
         m3u8_url = self._html_search_meta('video_url', webpage)
@@ -46,7 +46,7 @@ def _real_extract(self, url):
             thumbnails.append({
                 'url': thumbnail,
                 'width': width,
-                'height': int_or_none(try_get(width, lambda x: x * height_a / width_a))
+                'height': int_or_none(try_get(width, lambda x: x * height_a / width_a)),
             })
         m3u8_url = self._download_json(
             f'https://olympics.com/tokenGenerator?url={m3u8_url}', uuid, note='Downloading m3u8 url')
@@ -58,5 +58,5 @@ def _real_extract(self, url):
             'thumbnails': thumbnails,
             'formats': formats,
             'subtitles': subtitles,
-            **json_ld
+            **json_ld,
         }