do not return possibly zero timestamp

Authored by: bashonly
This commit is contained in:
bashonly 2025-05-20 16:06:41 -05:00
parent b7e8d0cf48
commit 65b17ffbb9
No known key found for this signature in database
GPG Key ID: 783F096F253D15B0

View File

@ -1059,7 +1059,7 @@ class TwitchStreamIE(TwitchVideosBaseIE):
if self.get_param('live_from_start'):
self.to_screen(f'{channel_name}: Extracting VOD to download live from start')
entry = next(self._entries(channel_name, None, 'time'), None)
if entry and entry['timestamp'] >= (timestamp or float('inf')):
if entry and entry.pop('timestamp') >= (timestamp or float('inf')):
return entry
self.report_warning(
'Unable to extract the VOD associated with this livestream', video_id=channel_name)