1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-10 13:40:06 +00:00

Added error handling

This commit is contained in:
Todd Martin
2025-03-20 16:39:11 -04:00
parent 9cae20f11e
commit 0d1b17f688

View File

@@ -567,12 +567,14 @@ export class LoginViaAuthRequestComponent implements OnInit, OnDestroy {
await this.reloadCachedStandardAuthRequestIfOneExists();
}
} catch (error) {
if (error instanceof ErrorResponse && error.statusCode === HttpStatusCode.NotFound) {
return await this.clearExistingStandardAuthRequestAndStartNewRequest();
}
if (error instanceof ErrorResponse) {
await this.router.navigate([this.backToRoute]);
this.validationService.showError(error);
return;
}
this.logService.error(error);
} finally {
// Manually clean out the cache to make sure sensitive