Skip to content

Commit

Permalink
Added the authorize guard.
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Kulik committed Jul 25, 2019
1 parent 9097a71 commit 0e24a7a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/ClientApp/src/app/app-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { HomeComponent } from "./home/home.component";
import { DataComponent } from "./data/data.component";
import { AuthorizeGuard } from "./api-authorization/authorize.guard";


const routes: Routes = [
{ path: '', component: HomeComponent, pathMatch: 'full' },
{ path: 'data', component: DataComponent }
{ path: 'data', component: DataComponent, canActivate: [AuthorizeGuard] }
];


Expand Down

0 comments on commit 0e24a7a

Please sign in to comment.