PLT-2020 Fix Clicking save without changing your email shows an error message (#3008)
Этот коммит содержится в:
@@ -160,6 +160,11 @@ class UserSettingsGeneralTab extends React.Component {
|
||||
const email = this.state.email.trim().toLowerCase();
|
||||
const confirmEmail = this.state.confirmEmail.trim().toLowerCase();
|
||||
|
||||
if (user.email === email) {
|
||||
this.updateSection('');
|
||||
return;
|
||||
}
|
||||
|
||||
const {formatMessage} = this.props.intl;
|
||||
if (email === '' || !Utils.isEmail(email)) {
|
||||
this.setState({emailError: formatMessage(holders.validEmail), clientError: '', serverError: ''});
|
||||
@@ -171,11 +176,6 @@ class UserSettingsGeneralTab extends React.Component {
|
||||
return;
|
||||
}
|
||||
|
||||
if (user.email === email) {
|
||||
this.updateSection('');
|
||||
return;
|
||||
}
|
||||
|
||||
user.email = email;
|
||||
this.submitUser(user, true);
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user