diff options
Diffstat (limited to 'gn_auth/auth')
-rw-r--r-- | gn_auth/auth/authentication/oauth2/grants/authorisation_code_grant.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gn_auth/auth/authentication/oauth2/grants/authorisation_code_grant.py b/gn_auth/auth/authentication/oauth2/grants/authorisation_code_grant.py index 98c36ee..02a876b 100644 --- a/gn_auth/auth/authentication/oauth2/grants/authorisation_code_grant.py +++ b/gn_auth/auth/authentication/oauth2/grants/authorisation_code_grant.py @@ -82,8 +82,9 @@ def __query_authorization_code__( This is found to be necessary since the `AuthorizationCodeGrant` class(es) do not have a way to pass the database connection.""" def __auth_code__(conn) -> str: - the_code = authorisation_code(conn, code, client) - return the_code.maybe(None, lambda cde: cde) # type: ignore[misc, arg-type, return-value] + _code = authorisation_code(conn, code, client) + # type: ignore[misc, arg-type, return-value] + return _code.maybe(None, lambda cde: cde) return with_db_connection(__auth_code__) |