diff options
Diffstat (limited to 'client/src/app/shared/shared-moderation/user-ban-modal.component.ts')
-rw-r--r-- | client/src/app/shared/shared-moderation/user-ban-modal.component.ts | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/client/src/app/shared/shared-moderation/user-ban-modal.component.ts b/client/src/app/shared/shared-moderation/user-ban-modal.component.ts index 124e58669..f9a0381c5 100644 --- a/client/src/app/shared/shared-moderation/user-ban-modal.component.ts +++ b/client/src/app/shared/shared-moderation/user-ban-modal.component.ts | |||
@@ -3,7 +3,6 @@ import { Notifier, UserService } from '@app/core' | |||
3 | import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms' | 3 | import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms' |
4 | import { NgbModal } from '@ng-bootstrap/ng-bootstrap' | 4 | import { NgbModal } from '@ng-bootstrap/ng-bootstrap' |
5 | import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref' | 5 | import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref' |
6 | import { I18n } from '@ngx-translate/i18n-polyfill' | ||
7 | import { User } from '@shared/models' | 6 | import { User } from '@shared/models' |
8 | 7 | ||
9 | @Component({ | 8 | @Component({ |
@@ -23,8 +22,7 @@ export class UserBanModalComponent extends FormReactive implements OnInit { | |||
23 | private modalService: NgbModal, | 22 | private modalService: NgbModal, |
24 | private notifier: Notifier, | 23 | private notifier: Notifier, |
25 | private userService: UserService, | 24 | private userService: UserService, |
26 | private userValidatorsService: UserValidatorsService, | 25 | private userValidatorsService: UserValidatorsService |
27 | private i18n: I18n | ||
28 | ) { | 26 | ) { |
29 | super() | 27 | super() |
30 | } | 28 | } |
@@ -52,8 +50,8 @@ export class UserBanModalComponent extends FormReactive implements OnInit { | |||
52 | .subscribe( | 50 | .subscribe( |
53 | () => { | 51 | () => { |
54 | const message = Array.isArray(this.usersToBan) | 52 | const message = Array.isArray(this.usersToBan) |
55 | ? this.i18n('{{num}} users banned.', { num: this.usersToBan.length }) | 53 | ? $localize`${this.usersToBan.length} users banned.` |
56 | : this.i18n('User {{username}} banned.', { username: this.usersToBan.username }) | 54 | : $localize`User ${this.usersToBan.username} banned.` |
57 | 55 | ||
58 | this.notifier.success(message) | 56 | this.notifier.success(message) |
59 | 57 | ||