Skip to content

Commit

Permalink
Merge pull request #1982 from arturovt/fix-route
Browse files Browse the repository at this point in the history
fix: remove redundant `auth` prefix that lead to `/auth/auth/login`
  • Loading branch information
arturovt committed May 15, 2020
2 parents 5a97be5 + b001603 commit e8cae40
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions src/app/auth/auth-routing.module.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';

import {LoginComponent} from './login/login.component';
import {RegisterComponent} from './register/register.component';
import { LoginComponent } from './login/login.component';
import { RegisterComponent } from './register/register.component';

const routes: Routes = [{
path: 'auth',
children: [{
const routes: Routes = [
{
path: '',
redirectTo: '/auth/login',
pathMatch: 'full'
}, {
path: 'login',
component: LoginComponent
}, {
path: 'register',
component: RegisterComponent
}]
}];
children: [
{
path: '',
redirectTo: '/auth/login',
pathMatch: 'full',
},
{
path: 'login',
component: LoginComponent,
},
{
path: 'register',
component: RegisterComponent,
},
],
},
];

@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule]
})

export class AuthRoutingModule { }
export const AuthRoutingModule = RouterModule.forChild(routes);

0 comments on commit e8cae40

Please sign in to comment.