diff --git a/youtube-channel-list.py b/youtube-channel-list.py index a7dbfae..ea6a6a9 100644 --- a/youtube-channel-list.py +++ b/youtube-channel-list.py @@ -10,7 +10,7 @@ with yt_dlp.YoutubeDL({'quiet': True}) as ydl: q.append(ie.extract(url)) while q: e = q.popleft() - if 'entries' in e: + if e['_type'] == 'playlist': q.extend(e['entries']) - elif 'id' in e: + elif e['_type'] == 'url': print(e['id'])