]> jfr.im git - yt-dlp.git/commitdiff
[ie/twitcasting] Fix livestream extraction (#8427)
authorsaintliao <redacted>
Fri, 27 Oct 2023 23:59:13 +0000 (07:59 +0800)
committerGitHub <redacted>
Fri, 27 Oct 2023 23:59:13 +0000 (23:59 +0000)
Closes #8431
Authored by: JC-Chung, saintliao

Co-authored-by: JC-Chung <redacted>
yt_dlp/extractor/twitcasting.py

index 540e217fd87b2e5c1590403de07ba51a8a79bbc9..32a38c86efb8221fc6e9e932d880ee1988653766 100644 (file)
@@ -142,7 +142,7 @@ def _real_extract(self, url):
             'https://twitcasting.tv/streamserver.php?target=%s&mode=client' % uploader_id, video_id,
             'Downloading live info', fatal=False)
 
-        is_live = 'data-status="online"' in webpage
+        is_live = any(f'data-{x}' in webpage for x in ['is-onlive="true"', 'live-type="live"', 'status="online"'])
         if not traverse_obj(stream_server_data, 'llfmp4') and is_live:
             self.raise_login_required(method='cookies')