]> jfr.im git - yt-dlp.git/commitdiff
[extractor] Do not exit early for unsuitable `url_result`
authorpukkandan <redacted>
Fri, 24 Mar 2023 16:23:45 +0000 (21:53 +0530)
committerpukkandan <redacted>
Sat, 25 Mar 2023 07:48:21 +0000 (13:18 +0530)
yt_dlp/extractor/common.py

index 2091df7fafce774df9a37cbca253ae9428b40ef7..5da12725ae30a8c56e9498aca7892faa8e893096 100644 (file)
@@ -3513,8 +3513,8 @@ def _RETURN_TYPE(cls):
     @classmethod
     def is_single_video(cls, url):
         """Returns whether the URL is of a single video, None if unknown"""
-        assert cls.suitable(url), 'The URL must be suitable for the extractor'
-        return {'video': True, 'playlist': False}.get(cls._RETURN_TYPE)
+        if cls.suitable(url):
+            return {'video': True, 'playlist': False}.get(cls._RETURN_TYPE)
 
     @classmethod
     def is_suitable(cls, age_limit):