Web.Client: Confirm: activateUser: fixed appearing error in the case of empty password field

This commit is contained in:
Daniil Senkiv 2019-10-08 10:31:15 +03:00
parent 38f9cacd5e
commit 838a56f6b7

View File

@ -95,7 +95,10 @@ class Confirm extends React.PureComponent {
this.setState({ passwordValid: !hasError });
}
!this.state.password.trim() && this.setState({ passwordEmpty: true });
if (!this.state.password.trim()) {
this.setState({ passwordEmpty: true });
hasError = true;
}
if (hasError) {
this.setState({ isLoading: false });