Show success message to the user

This commit is contained in:
Dane Everitt
2019-06-11 23:19:43 -07:00
parent 435626f4b7
commit 19ef901768
3 changed files with 8 additions and 8 deletions

View File

@@ -33,13 +33,12 @@ class ForgotPasswordContainer extends React.PureComponent<Props, State> {
this.setState({ isSubmitting: true }, () => {
this.props.clearAllFlashMessages();
requestPasswordResetEmail(this.state.email)
.then(() => {
// @todo actually handle this.
})
.then(response => this.props.pushFlashMessage({
type: 'success', title: 'Success', message: response,
}))
.catch(error => {
console.error(error);
this.props.pushFlashMessage({
id: 'auth:forgot-password',
type: 'error',
title: 'Error',
message: httpErrorToHuman(error),