From be72696ece18a8d9879e466ed4f8ab9e69250b70 Mon Sep 17 00:00:00 2001 From: venkataakhil Date: Sat, 24 Jun 2023 16:44:01 +0530 Subject: [PATCH] Refresh token pass aruguments from request --- smart_service/apis/app_user_login.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/smart_service/apis/app_user_login.py b/smart_service/apis/app_user_login.py index 780c77b..72273c9 100644 --- a/smart_service/apis/app_user_login.py +++ b/smart_service/apis/app_user_login.py @@ -862,11 +862,12 @@ def refresh_token(): rate_res = custom_rate_limit(limit=5, seconds=15) if rate_res != 1: return rate_res + + frappe.set_user("Administrator") + req = frappe.request.data + req = json.loads(req) + refresh_token= req['refresh_token'] if refresh_token: - frappe.set_user("Administrator") - req = frappe.request.data - req = json.loads(req) - refresh_token= req['refresh_token'] device_id= req['DeviceID'] # frappe.log_error('') # req = json.loads(frappe.request.data)