From 471c2e097cab85d32eb153c1f88bc24ecae3f37a Mon Sep 17 00:00:00 2001 From: lpm0073 Date: Thu, 6 Oct 2022 13:31:16 -0500 Subject: [PATCH] update self.user_details if we receive an extended dict --- wp_oauth_backend/wp_oauth.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/wp_oauth_backend/wp_oauth.py b/wp_oauth_backend/wp_oauth.py index 6fdb393..14007cf 100644 --- a/wp_oauth_backend/wp_oauth.py +++ b/wp_oauth_backend/wp_oauth.py @@ -285,14 +285,17 @@ class StepwiseMathWPOAuth2(BaseOAuth2): # user_details dict. This is created when get_user_details() # is called from user_data(). # ------------------------------------------------------------- + self.user_details = response if VERBOSE_LOGGING: logger.info( "get_user_details() returning {t}: {response}".format( t=self.get_response_type(response), - response=json.dumps(response, sort_keys=True, indent=4), + response=json.dumps( + self.user_details, sort_keys=True, indent=4 + ), ) ) - return response + return self.user_details # at this point we've ruled out the possibility of the response object # being a derivation of a user_details dict. So, it should therefore