Skip to main content

yt-dlp: fix an issue with YouTube playlist detection

ID
e1e0aea
date
2026-05-23 21:20:21+00:00
author
Alex Chan <alex@alexwlchan.net>
parent
f1f050c
message
yt-dlp: fix an issue with YouTube playlist detection
changed files
1 file, 1 addition, 1 deletion

Changed files

web/yt-dlp.py (4016) → web/yt-dlp.py (4022)

diff --git a/web/yt-dlp.py b/web/yt-dlp.py
index ab609e2..02d49c5 100755
--- a/web/yt-dlp.py
+++ b/web/yt-dlp.py
@@ -35,7 +35,7 @@ def is_youtube_playlist(url: str) -> bool:
     query = urllib.parse.parse_qs(u.query)
 
     # Look for a non-empty playlist which isn't WL (Watch Later)
-    return bool(query.get("list") and u["list"] != "WL")
+    return bool(query.get("list") and query["list"] != ["WL"])
 
 
 def get_playlist_video_ids(youtube_url: str) -> Iterator[str]: