fix: Enhance the error message of the connected app authorization.
Error were "Invalid state". The reason was user who created the token. So we've added a little bit more context here. (cherry picked from commit 4ad55b98c28d4c342808d166e7c124b89729607e)
This commit is contained in:
parent
8aed92d569
commit
733edd2ffd
1 changed files with 1 additions and 1 deletions
|
|
@ -194,7 +194,7 @@ def callback(code=None, state=None):
|
|||
token_cache = frappe.get_doc("Token Cache", connected_app.name + "-" + frappe.session.user)
|
||||
|
||||
if state != token_cache.state:
|
||||
frappe.throw(_("Invalid state."))
|
||||
frappe.throw(_("Invalid state! Check if token is created by the oath user."))
|
||||
|
||||
oauth_session = connected_app.get_oauth2_session(init=True)
|
||||
query_params = connected_app.get_query_params()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue