From 704be46266c1f4195e2d52203fc054f70b6203a1 Mon Sep 17 00:00:00 2001 From: Eric Ellingson Date: Tue, 7 Nov 2017 06:20:32 -0600 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fixed=20password=20fields=20not?= =?UTF-8?q?=20being=20cleared=20when=20leaving=20team/user=20page=20(#900)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit closes TryGhost/Ghost#9174 - Added `willTransition` action which clears the password input fields when transitioning to a new route --- ghost/admin/app/routes/team/user.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ghost/admin/app/routes/team/user.js b/ghost/admin/app/routes/team/user.js index 30613ece1e..3d14cadb9c 100644 --- a/ghost/admin/app/routes/team/user.js +++ b/ghost/admin/app/routes/team/user.js @@ -33,6 +33,11 @@ export default AuthenticatedRoute.extend(styleBody, CurrentUserSettings, { }, actions: { + willTransition() { + this.controller.set('user.password', ''); + this.controller.set('user.newPassword', ''); + this.controller.set('user.ne2Password', ''); + }, didTransition() { this.modelFor('team.user').get('errors').clear(); },