diff --git a/yt_dlp/extractor/tvw.py b/yt_dlp/extractor/tvw.py index c2e3235d5..e1a8b8b61 100644 --- a/yt_dlp/extractor/tvw.py +++ b/yt_dlp/extractor/tvw.py @@ -100,9 +100,9 @@ def _real_extract(self, url): except ExtractorError as e: if isinstance(e.cause, HTTPError): self.write_debug(e.cause) - response = self._parse_json(e.cause.response.read().decode(), video_id)['errors'] - if response['hasError'] is True: - raise ExtractorError('{} said: {}'.format(self.IE_NAME, response['error']), expected=True) + response = self._parse_json(e.cause.response.read().decode(), video_id).get('errors') + if response.get('hasError') is True: + raise ExtractorError('{} said: {}'.format(self.IE_NAME, response.get('error')), expected=True) raise stream_url = traverse_obj(response, ('streamingURIs', 'main'))