]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/cineverse.py
[ie/crunchyroll] Fix stream extraction (#10005)
[yt-dlp.git] / yt_dlp / extractor / cineverse.py
index c9fa789b78c7a824321345ea172f86897a5bffab..4405297c62e0937b045223f272f2e0200b2d752f 100644 (file)
@@ -13,7 +13,7 @@
 
 
 class CineverseBaseIE(InfoExtractor):
-    _VALID_URL_BASE = r'https://www\.(?P<host>%s)' % '|'.join(map(re.escape, (
+    _VALID_URL_BASE = r'https?://www\.(?P<host>%s)' % '|'.join(map(re.escape, (
         'cineverse.com',
         'asiancrush.com',
         'dovechannel.com',
@@ -67,7 +67,10 @@ def _real_extract(self, url):
         html = self._download_webpage(url, video_id)
         idetails = self._search_nextjs_data(html, video_id)['props']['pageProps']['idetails']
 
-        if idetails.get('err_code') == 1200:
+        err_code = idetails.get('err_code')
+        if err_code == 1002:
+            self.raise_login_required()
+        elif err_code == 1200:
             self.raise_geo_restricted(
                 'This video is not available from your location due to geo restriction. '
                 'You may be able to bypass it by using the /details/ page instead of the /watch/ page',