autowp/autowp-frontend

View on GitHub
src/app/account/account-routing.module.ts

Summary

Maintainability
C
1 day
Test Coverage
import {Routes} from '@angular/router';
 
import {authGuard} from '../auth.guard';
 
export const routes: Routes = [
{
children: [
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () => import('./access/access.component').then((m) => m.AccountAccessComponent),
path: 'access',
title: $localize`Access Control`,
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () => import('./accounts/accounts.component').then((m) => m.AccountAccountsComponent),
path: 'accounts',
title: $localize`My accounts`,
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () => import('./contacts/contacts.component').then((m) => m.AccountContactsComponent),
path: 'contacts',
title: $localize`Contacts`,
},
{
children: [
Similar blocks of code found in 33 locations. Consider refactoring.
{
loadComponent: () => import('./delete/deleted/deleted.component').then((m) => m.AccountDeletedComponent),
path: 'deleted',
title: $localize`Account deleted`,
},
{
canActivate: [authGuard],
loadComponent: () => import('./delete/delete.component').then((m) => m.AccountDeleteComponent),
path: '',
},
],
path: 'delete',
title: $localize`Account delete`,
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () => import('./email/email.component').then((m) => m.AccountEmailComponent),
path: 'email',
title: $localize`My e-mail`,
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () =>
import('./inbox-pictures/inbox-pictures.component').then((m) => m.AccountInboxPicturesComponent),
path: 'inbox-pictures',
title: $localize`Unmoderated`,
},
{
canActivate: [authGuard],
loadComponent: () => import('./messages/messages.component').then((m) => m.AccountMessagesComponent),
path: 'messages',
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () => import('./profile/profile.component').then((m) => m.AccountProfileComponent),
path: 'profile',
title: $localize`Profile`,
},
Similar blocks of code found in 26 locations. Consider refactoring.
{
canActivate: [authGuard],
loadComponent: () =>
import('./specs-conflicts/specs-conflicts.component').then((m) => m.AccountSpecsConflictsComponent),
path: 'specs-conflicts',
title: $localize`Conflicts`,
},
],
loadComponent: () => import('./account.component').then((m) => m.AccountComponent),
path: '',
title: $localize`Account`,
},
{path: '', pathMatch: 'full', redirectTo: 'profile'},
];