From 30d19844f2cd24c0b1640dfa66837c82634310ce Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Mon, 22 Nov 2021 10:45:01 +0100 Subject: [PATCH] Always callback if there is a callback, even if no auth data Because not having auth data is a reason to return no profile too. Otherwise the other side might wait for a response for a long time. Contributes to issue CURA-8539. --- cura/OAuth2/AuthorizationService.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cura/OAuth2/AuthorizationService.py b/cura/OAuth2/AuthorizationService.py index c9f60ddf2d..fb2ba40c71 100644 --- a/cura/OAuth2/AuthorizationService.py +++ b/cura/OAuth2/AuthorizationService.py @@ -89,6 +89,9 @@ class AuthorizationService: self.deleteAuthData() if callback is not None: callback(None) + else: + if callback is not None: + callback(None) self._parseJWT(callback = store_profile)