aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'yt_dlp/utils.py')
-rw-r--r--yt_dlp/utils.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/yt_dlp/utils.py b/yt_dlp/utils.py
index f93573692..d655bfdd0 100644
--- a/yt_dlp/utils.py
+++ b/yt_dlp/utils.py
@@ -3793,6 +3793,9 @@ class download_range_func:
self.chapters, self.ranges = chapters, ranges
def __call__(self, info_dict, ydl):
+ if not self.ranges and not self.chapters:
+ yield {}
+
warning = ('There are no chapters matching the regex' if info_dict.get('chapters')
else 'Cannot match chapters since chapter information is unavailable')
for regex in self.chapters or []: