Pre commit
This commit is contained in:
parent
49d764bd3f
commit
0bd3503608
|
@ -14,6 +14,7 @@ from keycloak import KeycloakOpenID # type: ignore
|
||||||
from werkzeug.wrappers.response import Response
|
from werkzeug.wrappers.response import Response
|
||||||
|
|
||||||
from spiffworkflow_backend.services.authorization_service import AuthorizationService
|
from spiffworkflow_backend.services.authorization_service import AuthorizationService
|
||||||
|
|
||||||
# from keycloak.uma_permissions import AuthStatus # noqa: F401
|
# from keycloak.uma_permissions import AuthStatus # noqa: F401
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -52,7 +52,7 @@ class AuthorizationService:
|
||||||
code="token_error",
|
code="token_error",
|
||||||
message=f"Exception in get_user_info_from_id_token: {e}",
|
message=f"Exception in get_user_info_from_id_token: {e}",
|
||||||
status_code=401,
|
status_code=401,
|
||||||
)
|
) from e
|
||||||
|
|
||||||
if request_response.status_code == 401:
|
if request_response.status_code == 401:
|
||||||
raise ApiError(
|
raise ApiError(
|
||||||
|
@ -64,7 +64,7 @@ class AuthorizationService:
|
||||||
|
|
||||||
raise ApiError(
|
raise ApiError(
|
||||||
code="user_info_error",
|
code="user_info_error",
|
||||||
message=f"Cannot get user info in get_user_info_from_id_token",
|
message="Cannot get user info in get_user_info_from_id_token",
|
||||||
status_code=401,
|
status_code=401,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue