Skip to content

A feature-rich command-line audio/video downloader

[youtube] Make category optional (#4442)

Philipp Hagemeister624dcebff617
diff --git a/youtube_dl/extractor/youtube.py b/youtube_dl/extractor/youtube.py
index f8d5cdd5d6..003aeaee6d 100644
--- a/youtube_dl/extractor/youtube.py
+++ b/youtube_dl/extractor/youtube.py
@@ -866,7 +866,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
m_cat_container = self._search_regex(
r'(?s)<h4[^>]*>\s*Category\s*</h4>\s*<ul[^>]*>(.*?)</ul>',
- video_webpage, 'categories', fatal=False)
+ video_webpage, 'categories', default=None)
if m_cat_container:
category = self._html_search_regex(
r'(?s)<a[^<]+>(.*?)</a>', m_cat_container, 'category',