From 1758bc678fe2f3cced4dc1c0ea268ad05b036a6d Mon Sep 17 00:00:00 2001 From: Raymond Penners Date: Tue, 30 Jul 2024 12:51:43 +0200 Subject: [PATCH] fix(socialaccount): token str mixup at PayPal, Salesforce --- allauth/socialaccount/providers/paypal/views.py | 2 +- allauth/socialaccount/providers/salesforce/views.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/allauth/socialaccount/providers/paypal/views.py b/allauth/socialaccount/providers/paypal/views.py index d92a9ad8db..2bee15cf80 100644 --- a/allauth/socialaccount/providers/paypal/views.py +++ b/allauth/socialaccount/providers/paypal/views.py @@ -37,7 +37,7 @@ def complete_login(self, request, app, token, **kwargs): .get_requests_session() .post( self.profile_url, - params={"schema": "openid", "access_token": token}, + params={"schema": "openid", "access_token": token.token}, ) ) extra_data = response.json() diff --git a/allauth/socialaccount/providers/salesforce/views.py b/allauth/socialaccount/providers/salesforce/views.py index f325a5c101..6e1a37d846 100644 --- a/allauth/socialaccount/providers/salesforce/views.py +++ b/allauth/socialaccount/providers/salesforce/views.py @@ -29,7 +29,7 @@ def complete_login(self, request, app, token, **kwargs): resp = ( get_adapter() .get_requests_session() - .get(self.userinfo_url, params={"oauth_token": token}) + .get(self.userinfo_url, params={"oauth_token": token.token}) ) resp.raise_for_status() extra_data = resp.json()