mirror of https://github.com/yt-dlp/yt-dlp.git
[ie/Boosty] improve error handling during auth cookie parsing
This commit is contained in:
parent
c1f7be9b01
commit
72a8e24ed4
|
@ -171,7 +171,7 @@ class BoostyIE(InfoExtractor):
|
|||
if auth_cookie is not None:
|
||||
try:
|
||||
auth_data = json.loads(compat_urllib_parse_unquote(auth_cookie.value))
|
||||
auth_headers['Authorization'] = f'Bearer {auth_data.get("accessToken")}'
|
||||
auth_headers['Authorization'] = f'Bearer {auth_data["accessToken"]}'
|
||||
except (json.JSONDecodeError, KeyError):
|
||||
self.report_warning('Failed to extract token from auth cookie.')
|
||||
|
||||
|
|
Loading…
Reference in New Issue