aboutsummaryrefslogtreecommitdiffhomepage
path: root/youtube_dl/YoutubeDL.py
diff options
context:
space:
mode:
authordirkf <[email protected]>2023-01-09 01:00:13 +0000
committerGitHub <[email protected]>2023-01-09 01:00:13 +0000
commit72c431725ae4387c8d28a96ebfb33ae59cff4a8d (patch)
tree05723c0441562c5e3ca72b3fe7eaf27a606b27a1 /youtube_dl/YoutubeDL.py
parent080c5d48ed23c8482fac63e95604a96fd48c1912 (diff)
downloadyoutube-dl-72c431725ae4387c8d28a96ebfb33ae59cff4a8d.tar.gz
youtube-dl-72c431725ae4387c8d28a96ebfb33ae59cff4a8d.zip
Diffstat (limited to 'youtube_dl/YoutubeDL.py')
-rwxr-xr-xyoutube_dl/YoutubeDL.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.py
index 55d50ead6..b03a89390 100755
--- a/youtube_dl/YoutubeDL.py
+++ b/youtube_dl/YoutubeDL.py
@@ -1311,7 +1311,7 @@ class YoutubeDL(object):
# or video only (imgur)) we will fallback to best/worst
# {video,audio}-only format
elif ctx['incomplete_formats']:
- return list(fmts)[format_idx]
+ return fmts[format_idx]
formats = list(ctx['formats'])
if not formats:
@@ -1336,7 +1336,7 @@ class YoutubeDL(object):
filter_f = lambda f: f['ext'] == format_spec
else:
filter_f = lambda f: f['format_id'] == format_spec
- formats = best_worst(filter(filter_f, formats))
+ formats = best_worst(list(filter(filter_f, formats)))
for f in variadic(formats or []):
yield f
elif selector.type == MERGE: