mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-13 06:19:02 +08:00
Fix crash with login
Fixes CURA-2N2
This commit is contained in:
parent
ebee7dbec9
commit
6dc65a4912
@ -99,7 +99,14 @@ class AuthorizationService:
|
|||||||
# If no auth data exists, we should always log in again.
|
# If no auth data exists, we should always log in again.
|
||||||
Logger.log("d", "There was no auth data or access token")
|
Logger.log("d", "There was no auth data or access token")
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
try:
|
||||||
user_data = self._auth_helpers.parseJWT(self._auth_data.access_token)
|
user_data = self._auth_helpers.parseJWT(self._auth_data.access_token)
|
||||||
|
except AttributeError:
|
||||||
|
# THis might seem a bit double, but we get crash reports about this (CURA-2N2 in sentry)
|
||||||
|
Logger.log("d", "There was no auth data or access token")
|
||||||
|
return None
|
||||||
|
|
||||||
if user_data:
|
if user_data:
|
||||||
# If the profile was found, we return it immediately.
|
# If the profile was found, we return it immediately.
|
||||||
return user_data
|
return user_data
|
||||||
|
Loading…
x
Reference in New Issue
Block a user