import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { filter } from 'rxjs/operators'
-import { AuthService } from '@app/core';
-import { User } from '../../../../../../shared';
+import { AuthService } from '@app/core'
+import { User } from '../../../../../../shared'
@Component({
selector: 'my-account-change-password',
checkPassword () {
this.error = null
- const oldPassword = this.form.value[ 'old-password' ];
+ const oldPassword = this.form.value[ 'old-password' ]
// compare old password
this.authService.login(this.user.account.name, oldPassword)
}
- private changePassword(){
+ private changePassword () {
this.userService.changePassword(this.form.value[ 'new-password' ]).subscribe(
() => {
this.notificationsService.success(this.i18n('Success'), this.i18n('Password updated.'))