Only admins should be able to create new users (#896)

This commit is contained in:
Joseph Milazzo 2022-01-05 11:04:45 -08:00 committed by GitHub
parent c5f69a5d0e
commit 70f7f34ac9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View file

@ -4,7 +4,7 @@ import { AdminGuard } from '../_guards/admin.guard';
import { DashboardComponent } from './dashboard/dashboard.component';
const routes: Routes = [
{path: '**', component: DashboardComponent, pathMatch: 'full'},
{path: '**', component: DashboardComponent, pathMatch: 'full', canActivate: [AdminGuard]},
{
runGuardsAndResolvers: 'always',
canActivate: [AdminGuard],