From 9df52d660feb722404be00a50f3c8a612bec1c15 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 17 Aug 2021 14:42:53 +0200 Subject: Migrate client to eslint --- .../my-account-change-password.component.ts | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'client/src/app/+my-account/my-account-settings/my-account-change-password') diff --git a/client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts b/client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts index f91b2f37b..47e54dc23 100644 --- a/client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts +++ b/client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts @@ -1,7 +1,11 @@ import { filter } from 'rxjs/operators' import { Component, OnInit } from '@angular/core' import { AuthService, Notifier, UserService } from '@app/core' -import { USER_CONFIRM_PASSWORD_VALIDATOR, USER_PASSWORD_VALIDATOR, USER_EXISTING_PASSWORD_VALIDATOR } from '@app/shared/form-validators/user-validators' +import { + USER_CONFIRM_PASSWORD_VALIDATOR, + USER_EXISTING_PASSWORD_VALIDATOR, + USER_PASSWORD_VALIDATOR +} from '@app/shared/form-validators/user-validators' import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' import { User } from '@shared/models' @@ -19,7 +23,7 @@ export class MyAccountChangePasswordComponent extends FormReactive implements On private notifier: Notifier, private authService: AuthService, private userService: UserService - ) { + ) { super() } @@ -35,13 +39,13 @@ export class MyAccountChangePasswordComponent extends FormReactive implements On const confirmPasswordControl = this.form.get('new-confirmed-password') confirmPasswordControl.valueChanges - .pipe(filter(v => v !== this.form.value[ 'new-password' ])) + .pipe(filter(v => v !== this.form.value['new-password'])) .subscribe(() => confirmPasswordControl.setErrors({ matchPassword: true })) } changePassword () { - const currentPassword = this.form.value[ 'current-password' ] - const newPassword = this.form.value[ 'new-password' ] + const currentPassword = this.form.value['current-password'] + const newPassword = this.form.value['new-password'] this.userService.changePassword(currentPassword, newPassword) .subscribe({ -- cgit v1.2.3