Fix 781 invalid message on password reset failure (#1234)

* Updated to add button to redirect to forgot password page
This commit is contained in:
Akshay Avinash 2020-10-16 19:48:03 +05:30 committed by GitHub
parent 10fe3ba171
commit 4e99ab7ace
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 14 additions and 1 deletions

View File

@ -122,6 +122,19 @@ export const ResetPassword = (props: ResetPasswordProps) => {
}
if (showFailureMessage) {
message = error;
if (
message
.toLowerCase()
.includes(RESET_PASSWORD_FORGOT_PASSWORD_LINK.toLowerCase())
) {
messageActions = [
{
url: FORGOT_PASSWORD_URL,
text: RESET_PASSWORD_FORGOT_PASSWORD_LINK,
intent: "primary",
},
];
}
}
const messageTagProps: FormMessageProps = {

View File

@ -28,7 +28,7 @@ public enum AppsmithError {
USER_ALREADY_EXISTS_IN_ORGANIZATION(400, 4021, "The user {0} has already been added to the organization with role {1}"),
UNAUTHORIZED_DOMAIN(401, 4019, "Invalid email domain provided. Please sign in with a valid work email ID"),
USER_NOT_SIGNED_IN(401, 4020, "User is not logged in. Please sign in with the registered email ID or sign up" ),
INVALID_PASSWORD_RESET(400, 4020, "Unable to reset the password. Please initiate a request via 'forgot password' link to reset your password"),
INVALID_PASSWORD_RESET(400, 4020, "Unable to reset the password. Please initiate a request via 'forgot password' button to reset your password"),
LOGIN_INTERNAL_ERROR(401, 4021, "Internal error while trying to login"),
JSON_PROCESSING_ERROR(400, 4022, "Json processing error with error {0}"),
INVALID_CREDENTIALS(200, 4023, "Invalid credentials provided. Did you input the credentials correctly?"),