diff options
Diffstat (limited to 'client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts')
-rw-r--r-- | client/src/app/+my-account/my-account-settings/my-account-change-password/my-account-change-password.component.ts | 7 |
1 files changed, 3 insertions, 4 deletions
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 e5343b33d..cbb068c7c 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,11 +1,10 @@ | |||
1 | import { Component, OnInit } from '@angular/core' | 1 | import { Component, OnInit } from '@angular/core' |
2 | import { NotificationsService } from 'angular2-notifications' | 2 | import { AuthService, Notifier } from '@app/core' |
3 | import { FormReactive, UserService } from '../../../shared' | 3 | import { FormReactive, UserService } from '../../../shared' |
4 | import { I18n } from '@ngx-translate/i18n-polyfill' | 4 | import { I18n } from '@ngx-translate/i18n-polyfill' |
5 | import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service' | 5 | import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service' |
6 | import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service' | 6 | import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service' |
7 | import { filter } from 'rxjs/operators' | 7 | import { filter } from 'rxjs/operators' |
8 | import { AuthService } from '@app/core' | ||
9 | import { User } from '../../../../../../shared' | 8 | import { User } from '../../../../../../shared' |
10 | 9 | ||
11 | @Component({ | 10 | @Component({ |
@@ -20,7 +19,7 @@ export class MyAccountChangePasswordComponent extends FormReactive implements On | |||
20 | constructor ( | 19 | constructor ( |
21 | protected formValidatorService: FormValidatorService, | 20 | protected formValidatorService: FormValidatorService, |
22 | private userValidatorsService: UserValidatorsService, | 21 | private userValidatorsService: UserValidatorsService, |
23 | private notificationsService: NotificationsService, | 22 | private notifier: Notifier, |
24 | private authService: AuthService, | 23 | private authService: AuthService, |
25 | private userService: UserService, | 24 | private userService: UserService, |
26 | private i18n: I18n | 25 | private i18n: I18n |
@@ -50,7 +49,7 @@ export class MyAccountChangePasswordComponent extends FormReactive implements On | |||
50 | 49 | ||
51 | this.userService.changePassword(currentPassword, newPassword).subscribe( | 50 | this.userService.changePassword(currentPassword, newPassword).subscribe( |
52 | () => { | 51 | () => { |
53 | this.notificationsService.success(this.i18n('Success'), this.i18n('Password updated.')) | 52 | this.notifier.success(this.i18n('Password updated.')) |
54 | 53 | ||
55 | this.form.reset() | 54 | this.form.reset() |
56 | this.error = null | 55 | this.error = null |