aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/youtube.py
diff options
context:
space:
mode:
authorpukkandan <pukkandan.ytdlp@gmail.com>2022-01-21 13:27:40 +0530
committerpukkandan <pukkandan.ytdlp@gmail.com>2022-01-21 13:27:40 +0530
commite0ddbd02bd1c365b95bb88eaa6e4e0238faf35eb (patch)
tree8035bea649dee8e517380a8c3d6dc31a0436c2c3 /yt_dlp/extractor/youtube.py
parent0bfc53d05c7ecd7762313f0cd8578c46cd916519 (diff)
downloadhypervideo-pre-e0ddbd02bd1c365b95bb88eaa6e4e0238faf35eb.tar.lz
hypervideo-pre-e0ddbd02bd1c365b95bb88eaa6e4e0238faf35eb.tar.xz
hypervideo-pre-e0ddbd02bd1c365b95bb88eaa6e4e0238faf35eb.zip
[cleanup] Use format_field where applicable
Diffstat (limited to 'yt_dlp/extractor/youtube.py')
-rw-r--r--yt_dlp/extractor/youtube.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/yt_dlp/extractor/youtube.py b/yt_dlp/extractor/youtube.py
index 09a0b2279..d8a63a3d2 100644
--- a/yt_dlp/extractor/youtube.py
+++ b/yt_dlp/extractor/youtube.py
@@ -3331,7 +3331,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
'uploader_id': self._search_regex(r'/(?:channel|user)/([^/?&#]+)', owner_profile_url, 'uploader id') if owner_profile_url else None,
'uploader_url': owner_profile_url,
'channel_id': channel_id,
- 'channel_url': f'https://www.youtube.com/channel/{channel_id}' if channel_id else None,
+ 'channel_url': format_field(channel_id, template='https://www.youtube.com/channel/%s'),
'duration': duration,
'view_count': int_or_none(
get_first((video_details, microformats), (..., 'viewCount'))