summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorKhoa, Le Ngoc <khoaln6@gmail.com>2016-02-03 13:24:15 +0700
committerKhoa, Le Ngoc <khoaln6@gmail.com>2016-02-03 13:24:15 +0700
commit41bf14ade2ed815ffd794215f42d7a793bc3af2f (patch)
treea63cd5639270e5afc3902e31b9ff7fcede88ee61 /web
parentd31ae207389b7402debbcaa40bb691e86023f1ba (diff)
downloadchat-41bf14ade2ed815ffd794215f42d7a793bc3af2f.tar.gz
chat-41bf14ade2ed815ffd794215f42d7a793bc3af2f.tar.bz2
chat-41bf14ade2ed815ffd794215f42d7a793bc3af2f.zip
Clear the password input boxes when user enter incorrect Retype New Password.
Diffstat (limited to 'web')
-rw-r--r--web/react/components/user_settings/user_settings_security.jsx3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/react/components/user_settings/user_settings_security.jsx b/web/react/components/user_settings/user_settings_security.jsx
index 0c9e722de..5693047c2 100644
--- a/web/react/components/user_settings/user_settings_security.jsx
+++ b/web/react/components/user_settings/user_settings_security.jsx
@@ -88,7 +88,8 @@ class SecurityTab extends React.Component {
}
if (newPassword !== confirmPassword) {
- this.setState({passwordError: formatMessage(holders.passwordMatchError), serverError: ''});
+ var defaultState = Object.assign(this.getDefaultState(), {passwordError: formatMessage(holders.passwordMatchError), serverError: ''});
+ this.setState(defaultState);
return;
}