Skip to content

Commit 9bfb7df

Browse files
author
Jason Watmore
committed
removing leading slash from router redirect
1 parent 24c6fa7 commit 9bfb7df

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/_guards/auth.guard.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export class AuthGuard implements CanActivate {
1313
}
1414

1515
// not logged in so redirect to login page with the return url
16-
this.router.navigate(['/login'], { queryParams: { returnUrl: state.url }});
16+
this.router.navigate(['login'], { queryParams: { returnUrl: state.url }});
1717
return false;
1818
}
1919
}

app/register/register.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export class RegisterComponent {
2323
.subscribe(
2424
data => {
2525
this.alertService.success('Registration successful', true);
26-
this.router.navigate(['/login']);
26+
this.router.navigate(['login']);
2727
},
2828
error => {
2929
this.alertService.error(error);

0 commit comments

Comments
 (0)