0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-13 22:41:32 -05:00

Show error notifications on "reset password" page

closes #3330
- Caught errors are displayed using notifications util
This commit is contained in:
Felix Rieseberg 2014-07-22 14:03:57 -07:00
parent 4968336b0f
commit 80f71e31fd

View file

@ -32,16 +32,13 @@ var ResetController = Ember.Controller.extend(ValidationEngine, {
} }
}).then(function (resp) { }).then(function (resp) {
self.toggleProperty('submitting'); self.toggleProperty('submitting');
console.log('success');
self.transitionToRoute('signin'); self.transitionToRoute('signin');
}).catch(function (errors) { }).catch(function (errors) {
self.toggleProperty('submitting'); self.toggleProperty('submitting');
console.log('error');
}); });
}).catch(function (error) { }).catch(function (error) {
self.toggleProperty('submitting'); self.toggleProperty('submitting');
// @TODO: notifications here for validation errors self.notifications.showErrors(error);
console.log('validation error', error);
}); });
} }
} }