From 57e56eb2941cce88a2a9b538b3e6a761ece6a317 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 2 Jul 2020 10:32:11 +0200 Subject: Fix lint --- client/src/app/+admin/admin.component.ts | 59 +++++++++++++--------- client/src/app/+my-account/my-account.module.ts | 2 +- .../app/shared/shared-main/shared-main.module.ts | 2 +- 3 files changed, 36 insertions(+), 27 deletions(-) (limited to 'client/src') diff --git a/client/src/app/+admin/admin.component.ts b/client/src/app/+admin/admin.component.ts index c1c160ad1..51c64694f 100644 --- a/client/src/app/+admin/admin.component.ts +++ b/client/src/app/+admin/admin.component.ts @@ -19,22 +19,22 @@ export class AdminComponent implements OnInit { ) {} ngOnInit () { - const federationItems: TopMenuDropdownParam = { - label: this.i18n('Federation'), + const federationItems: TopMenuDropdownParam = { + label: this.i18n('Federation'), children: [ { label: this.i18n('Instances you follow'), - routerLink: '/admin/follows/following-list', + routerLink: '/admin/follows/following-list', iconName: 'sign-out' }, { label: this.i18n('Instances following you'), - routerLink: '/admin/follows/followers-list', + routerLink: '/admin/follows/followers-list', iconName: 'sign-in' }, { label: this.i18n('Video redundancies'), - routerLink: '/admin/follows/video-redundancies-list', + routerLink: '/admin/follows/video-redundancies-list', iconName: 'videos' } ] @@ -44,26 +44,35 @@ export class AdminComponent implements OnInit { label: this.i18n('Moderation'), children: [] } - if (this.hasVideoAbusesRight()) moderationItems.children.push({ - label: this.i18n('Video reports'), - routerLink: '/admin/moderation/video-abuses/list', - iconName: 'flag' - }) - if (this.hasVideoBlocklistRight()) moderationItems.children.push({ - label: this.i18n('Video blocks'), - routerLink: '/admin/moderation/video-blocks/list', - iconName: 'cross' - }) - if (this.hasAccountsBlocklistRight()) moderationItems.children.push({ - label: this.i18n('Muted accounts'), - routerLink: '/admin/moderation/blocklist/accounts', - iconName: 'user' - }) - if (this.hasServersBlocklistRight()) moderationItems.children.push({ - label: this.i18n('Muted servers'), - routerLink: '/admin/moderation/blocklist/servers', - iconName: 'server' - }) + + if (this.hasVideoAbusesRight()) { + moderationItems.children.push({ + label: this.i18n('Video reports'), + routerLink: '/admin/moderation/video-abuses/list', + iconName: 'flag' + }) + } + if (this.hasVideoBlocklistRight()) { + moderationItems.children.push({ + label: this.i18n('Video blocks'), + routerLink: '/admin/moderation/video-blocks/list', + iconName: 'cross' + }) + } + if (this.hasAccountsBlocklistRight()) { + moderationItems.children.push({ + label: this.i18n('Muted accounts'), + routerLink: '/admin/moderation/blocklist/accounts', + iconName: 'user' + }) + } + if (this.hasServersBlocklistRight()) { + moderationItems.children.push({ + label: this.i18n('Muted servers'), + routerLink: '/admin/moderation/blocklist/servers', + iconName: 'server' + }) + } if (this.hasUsersRight()) this.menuEntries.push({ label: this.i18n('Users'), routerLink: '/admin/users' }) if (this.hasServerFollowRight()) this.menuEntries.push(federationItems) diff --git a/client/src/app/+my-account/my-account.module.ts b/client/src/app/+my-account/my-account.module.ts index 0ce243844..742a516d5 100644 --- a/client/src/app/+my-account/my-account.module.ts +++ b/client/src/app/+my-account/my-account.module.ts @@ -77,7 +77,7 @@ import { MyAccountComponent } from './my-account.component' MyAccountVideoPlaylistCreateComponent, MyAccountVideoPlaylistUpdateComponent, MyAccountVideoPlaylistsComponent, - MyAccountVideoPlaylistElementsComponent, + MyAccountVideoPlaylistElementsComponent ], exports: [ diff --git a/client/src/app/shared/shared-main/shared-main.module.ts b/client/src/app/shared/shared-main/shared-main.module.ts index 04e3eb0af..732914e34 100644 --- a/client/src/app/shared/shared-main/shared-main.module.ts +++ b/client/src/app/shared/shared-main/shared-main.module.ts @@ -83,7 +83,7 @@ import { AUTH_INTERCEPTOR_PROVIDER } from './auth' ListOverflowComponent, TopMenuDropdownComponent, - UserNotificationsComponent, + UserNotificationsComponent ], exports: [ -- cgit v1.2.3