From 617f46835eb571e08cbe40352cab8c49df2a4952 Mon Sep 17 00:00:00 2001 From: Mart van Santen Date: Fri, 1 Apr 2022 16:45:25 +0800 Subject: [PATCH] Use getter to get value --- areas/login/login.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/areas/login/login.py b/areas/login/login.py index 214898e..d2be28a 100644 --- a/areas/login/login.py +++ b/areas/login/login.py @@ -235,7 +235,8 @@ def consent(): # Get information about this consent request: # False positive: pylint: disable=no-member try: - app_id = consent_request.client.client_id + consent_client = consent_request.client.get('client_id') + app_id = consent_client.get('client_id') # False positive: pylint: disable=no-member kratos_id = consent_request.subject except Exception as error: @@ -243,7 +244,6 @@ def consent(): current_app.logger.error(f"Error: {error}") current_app.logger.error(f"Client: {consent_request.client}") current_app.logger.error(f"Subject: {consent_request.subject}") - current_app.logger.error(f"Subject: {consent_request.client.client_id}") abort(501, description="Internal error occured") # Get the related user object