From a1680e3ce4f624f9e9131ae49c0a31600d1e1a04 Mon Sep 17 00:00:00 2001 From: Priyanka Upadhye <92uppr1mst@hft-stuttgart.de> Date: Mon, 6 Jan 2020 17:21:16 +0100 Subject: [PATCH] Validation of Password change --- src/app/auth/reset-password/reset-password.page.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/app/auth/reset-password/reset-password.page.ts b/src/app/auth/reset-password/reset-password.page.ts index bc4080e..8ed480d 100644 --- a/src/app/auth/reset-password/reset-password.page.ts +++ b/src/app/auth/reset-password/reset-password.page.ts @@ -33,8 +33,11 @@ export class ResetPasswordPage implements OnInit { resetPassword(){ if(this.oldPassword=="" || this.confirmPassword=="" || this.newPassword=="") this.toastService.showToast("All Feilds are mandatory"); + else if(this.newPassword.length < 4) + this.toastService.showToast("Weak Password"); else if(this.confirmPassword!=this.newPassword) this.toastService.showToast("Please Confirm Password Again"); + else{ this.storage.get('token').then((token) => { let url = 'http://193.196.52.237:8081/password-reset/' -- GitLab