mirror of
https://github.com/bitwarden/web
synced 2025-12-23 11:43:15 +00:00
Use jslib unauthGuard, add lockGuard support (#939)
* Use jslib unauthGuard, add lockGuard support * bump jslib
This commit is contained in:
@@ -33,13 +33,6 @@ export class LockComponent extends BaseLockComponent {
|
||||
|
||||
async ngOnInit() {
|
||||
await super.ngOnInit();
|
||||
const authed = await this.userService.isAuthenticated();
|
||||
if (!authed) {
|
||||
this.router.navigate(['/']);
|
||||
} else if (await this.cryptoService.hasKey()) {
|
||||
this.router.navigate(['vault']);
|
||||
}
|
||||
|
||||
this.onSuccessfulSubmit = () => {
|
||||
const previousUrl = this.routerService.getPreviousUrl();
|
||||
if (previousUrl !== '/' && previousUrl.indexOf('lock') === -1) {
|
||||
|
||||
Reference in New Issue
Block a user