mirror of
https://github.com/bitwarden/browser
synced 2025-12-17 08:43:33 +00:00
refactor to handleAuthResult() method
This commit is contained in:
@@ -177,7 +177,10 @@ export class LoginComponentV2 implements OnInit, OnDestroy {
|
|||||||
const authResult = await this.loginStrategyService.logIn(credentials);
|
const authResult = await this.loginStrategyService.logIn(credentials);
|
||||||
|
|
||||||
await this.saveEmailSettings();
|
await this.saveEmailSettings();
|
||||||
|
await this.handleAuthResult(authResult);
|
||||||
|
};
|
||||||
|
|
||||||
|
private async handleAuthResult(authResult: AuthResult): Promise<void> {
|
||||||
if (this.handleCaptchaRequired(authResult)) {
|
if (this.handleCaptchaRequired(authResult)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -224,7 +227,7 @@ export class LoginComponentV2 implements OnInit, OnDestroy {
|
|||||||
await this.router.navigate(["vault"]); // Desktop
|
await this.router.navigate(["vault"]); // Desktop
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
|
||||||
protected async goAfterLogIn(userId: UserId): Promise<void> {
|
protected async goAfterLogIn(userId: UserId): Promise<void> {
|
||||||
const masterPassword = this.formGroup.value.masterPassword;
|
const masterPassword = this.formGroup.value.masterPassword;
|
||||||
|
|||||||
Reference in New Issue
Block a user