fix(UX): forget password shows error on wrong email (#19235)
* fix: forget password shows error on wrong email * test: expected test failure [skip ci] Co-authored-by: Ankush Menat <ankush@frappe.io>
This commit is contained in:
parent
bb5b0e5e64
commit
b93022a54e
3 changed files with 4 additions and 3 deletions
|
|
@ -288,7 +288,7 @@ class TestUser(FrappeTestCase):
|
|||
c = FrappeClient(url)
|
||||
res1 = c.session.post(url, data=data, verify=c.verify, headers=c.headers)
|
||||
res2 = c.session.post(url, data=data, verify=c.verify, headers=c.headers)
|
||||
self.assertEqual(res1.status_code, 400)
|
||||
self.assertEqual(res1.status_code, 404)
|
||||
self.assertEqual(res2.status_code, 417)
|
||||
|
||||
def test_user_rename(self):
|
||||
|
|
|
|||
|
|
@ -891,7 +891,7 @@ def reset_password(user):
|
|||
title=_("Password Email Sent"),
|
||||
)
|
||||
except frappe.DoesNotExistError:
|
||||
frappe.local.response["http_status_code"] = 400
|
||||
frappe.local.response["http_status_code"] = 404
|
||||
frappe.clear_messages()
|
||||
return "not found"
|
||||
|
||||
|
|
|
|||
|
|
@ -253,7 +253,8 @@ login.login_handlers = (function () {
|
|||
}
|
||||
},
|
||||
401: get_error_handler('{{ _("Invalid Login. Try again.") }}'),
|
||||
417: get_error_handler('{{ _("Oops! Something went wrong") }}')
|
||||
417: get_error_handler('{{ _("Oops! Something went wrong") }}'),
|
||||
404: get_error_handler('{{ _("User does not exist.")}}')
|
||||
};
|
||||
|
||||
return login_handlers;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue