From 264372a2a3344d7ffe8482b88fb6407bb3335393 Mon Sep 17 00:00:00 2001 From: Shariq Ansari Date: Tue, 18 Jul 2023 17:15:58 +0530 Subject: [PATCH] fix: show list of user details that we are giving access to if scope is openid --- frappe/integrations/oauth2.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/frappe/integrations/oauth2.py b/frappe/integrations/oauth2.py index 7abcfb5655..bf71a68aaa 100644 --- a/frappe/integrations/oauth2.py +++ b/frappe/integrations/oauth2.py @@ -101,6 +101,10 @@ def authorize(**kwargs): frappe.local.response["type"] = "redirect" frappe.local.response["location"] = success_url else: + if "openid" in scopes: + scopes.remove("openid") + scopes.extend(["First Name", "Last Name", "Email", "Password", "User Image", "Roles"]) + # Show Allow/Deny screen. response_html_params = frappe._dict( {