X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=client%2Fsrc%2Fapp%2Fcore%2Frouting%2Flogin-guard.service.ts;h=7b1c37ee8929976022d60ff1592d4ef9fcf28e58;hb=2f5d2ec5ea4fedf2466e1db2d16878b1467b1e05;hp=40ff8f5059491177fd9695e01ec22c675aed81cc;hpb=ec769c89fdcbcaf2d15de8d211d3ede3b6f69c1a;p=github%2FChocobozzz%2FPeerTube.git diff --git a/client/src/app/core/routing/login-guard.service.ts b/client/src/app/core/routing/login-guard.service.ts index 40ff8f505..7b1c37ee8 100644 --- a/client/src/app/core/routing/login-guard.service.ts +++ b/client/src/app/core/routing/login-guard.service.ts @@ -1,11 +1,5 @@ import { Injectable } from '@angular/core' -import { - ActivatedRouteSnapshot, - CanActivateChild, - RouterStateSnapshot, - CanActivate, - Router -} from '@angular/router' +import { ActivatedRouteSnapshot, CanActivate, CanActivateChild, Router, RouterStateSnapshot } from '@angular/router' import { AuthService } from '../auth/auth.service' @@ -20,8 +14,6 @@ export class LoginGuard implements CanActivate, CanActivateChild { canActivate (route: ActivatedRouteSnapshot, state: RouterStateSnapshot) { if (this.auth.isLoggedIn() === true) return true - this.auth.redirectUrl = state.url - this.router.navigate([ '/login' ]) return false }