diff options
Diffstat (limited to 'client/src/app/shared/shared-user-settings/user-interface-settings.component.ts')
-rw-r--r-- | client/src/app/shared/shared-user-settings/user-interface-settings.component.ts | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/client/src/app/shared/shared-user-settings/user-interface-settings.component.ts b/client/src/app/shared/shared-user-settings/user-interface-settings.component.ts index 875ffa3f1..80b88c129 100644 --- a/client/src/app/shared/shared-user-settings/user-interface-settings.component.ts +++ b/client/src/app/shared/shared-user-settings/user-interface-settings.component.ts | |||
@@ -2,7 +2,6 @@ import { Subject, Subscription } from 'rxjs' | |||
2 | import { Component, Input, OnDestroy, OnInit } from '@angular/core' | 2 | import { Component, Input, OnDestroy, OnInit } from '@angular/core' |
3 | import { AuthService, Notifier, ServerService, UserService } from '@app/core' | 3 | import { AuthService, Notifier, ServerService, UserService } from '@app/core' |
4 | import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' | 4 | import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' |
5 | import { I18n } from '@ngx-translate/i18n-polyfill' | ||
6 | import { ServerConfig, User, UserUpdateMe } from '@shared/models' | 5 | import { ServerConfig, User, UserUpdateMe } from '@shared/models' |
7 | 6 | ||
8 | @Component({ | 7 | @Component({ |
@@ -25,8 +24,7 @@ export class UserInterfaceSettingsComponent extends FormReactive implements OnIn | |||
25 | private authService: AuthService, | 24 | private authService: AuthService, |
26 | private notifier: Notifier, | 25 | private notifier: Notifier, |
27 | private userService: UserService, | 26 | private userService: UserService, |
28 | private serverService: ServerService, | 27 | private serverService: ServerService |
29 | private i18n: I18n | ||
30 | ) { | 28 | ) { |
31 | super() | 29 | super() |
32 | } | 30 | } |
@@ -73,14 +71,14 @@ export class UserInterfaceSettingsComponent extends FormReactive implements OnIn | |||
73 | () => { | 71 | () => { |
74 | this.authService.refreshUserInformation() | 72 | this.authService.refreshUserInformation() |
75 | 73 | ||
76 | if (this.notifyOnUpdate) this.notifier.success(this.i18n('Interface settings updated.')) | 74 | if (this.notifyOnUpdate) this.notifier.success($localize`Interface settings updated.`) |
77 | }, | 75 | }, |
78 | 76 | ||
79 | err => this.notifier.error(err.message) | 77 | err => this.notifier.error(err.message) |
80 | ) | 78 | ) |
81 | } else { | 79 | } else { |
82 | this.userService.updateMyAnonymousProfile(details) | 80 | this.userService.updateMyAnonymousProfile(details) |
83 | if (this.notifyOnUpdate) this.notifier.success(this.i18n('Interface settings updated.')) | 81 | if (this.notifyOnUpdate) this.notifier.success($localize`Interface settings updated.`) |
84 | } | 82 | } |
85 | } | 83 | } |
86 | } | 84 | } |