Fix login when showing an error (#329)
This commit is contained in:
parent
8610f9f943
commit
6296f39673
1 changed files with 8 additions and 4 deletions
|
|
@ -173,16 +173,20 @@ class Login extends Component {
|
|||
errorId === 'ent.ldap.do_login.user_not_registered.app_error'
|
||||
) {
|
||||
return {
|
||||
id: 'login.userNotFound',
|
||||
defaultMessage: "We couldn't find an account matching your login credentials."
|
||||
intl: {
|
||||
id: 'login.userNotFound',
|
||||
defaultMessage: "We couldn't find an account matching your login credentials."
|
||||
}
|
||||
};
|
||||
} else if (
|
||||
errorId === 'api.user.check_user_password.invalid.app_error' ||
|
||||
errorId === 'ent.ldap.do_login.invalid_password.app_error'
|
||||
) {
|
||||
return {
|
||||
id: 'login.invalidPassword',
|
||||
defaultMessage: 'Your password is incorrect.'
|
||||
intl: {
|
||||
id: 'login.invalidPassword',
|
||||
defaultMessage: 'Your password is incorrect.'
|
||||
}
|
||||
};
|
||||
}
|
||||
return error.message;
|
||||
|
|
|
|||
Loading…
Reference in a new issue