summaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/ustudio.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--yt_dlp/extractor/ustudio.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/yt_dlp/extractor/ustudio.py b/yt_dlp/extractor/ustudio.py
index f6ce5b3..b5da88b 100644
--- a/yt_dlp/extractor/ustudio.py
+++ b/yt_dlp/extractor/ustudio.py
@@ -21,14 +21,14 @@ class UstudioIE(InfoExtractor):
'thumbnail': r're:^https?://.*\.jpg$',
'upload_date': '20111107',
'uploader': 'Tony Farley',
- }
+ },
}
def _real_extract(self, url):
video_id, display_id = self._match_valid_url(url).groups()
config = self._download_xml(
- 'http://v1.ustudio.com/embed/%s/ustudio/config.xml' % video_id,
+ f'http://v1.ustudio.com/embed/{video_id}/ustudio/config.xml',
display_id)
def extract(kind):
@@ -36,7 +36,7 @@ class UstudioIE(InfoExtractor):
'url': unescapeHTML(item.attrib['url']),
'width': int_or_none(item.get('width')),
'height': int_or_none(item.get('height')),
- } for item in config.findall('./qualities/quality/%s' % kind) if item.get('url')]
+ } for item in config.findall(f'./qualities/quality/{kind}') if item.get('url')]
formats = extract('video')
@@ -74,13 +74,13 @@ class UstudioEmbedIE(InfoExtractor):
'title': '5 Things IT Should Know About Video',
'description': 'md5:93d32650884b500115e158c5677d25ad',
'uploader_id': 'DeN7VdYRDKhP',
- }
+ },
}
def _real_extract(self, url):
uploader_id, video_id = self._match_valid_url(url).groups()
video_data = self._download_json(
- 'http://app.ustudio.com/embed/%s/%s/config.json' % (uploader_id, video_id),
+ f'http://app.ustudio.com/embed/{uploader_id}/{video_id}/config.json',
video_id)['videos'][0]
title = video_data['name']
@@ -92,7 +92,7 @@ class UstudioEmbedIE(InfoExtractor):
continue
height = int_or_none(quality.get('height'))
formats.append({
- 'format_id': '%s-%dp' % (ext, height) if height else ext,
+ 'format_id': f'{ext}-{height}p' if height else ext,
'url': quality_url,
'width': int_or_none(quality.get('width')),
'height': height,