mirror of
https://github.com/bitwarden/jslib
synced 2025-12-06 00:03:29 +00:00
Add support for crypto agent (#520)
This commit is contained in:
@@ -140,7 +140,7 @@ export class SsoComponent {
|
||||
private async logIn(code: string, codeVerifier: string, orgIdFromState: string) {
|
||||
this.loggingIn = true;
|
||||
try {
|
||||
this.formPromise = this.authService.logInSso(code, codeVerifier, this.redirectUri);
|
||||
this.formPromise = this.authService.logInSso(code, codeVerifier, this.redirectUri, orgIdFromState);
|
||||
const response = await this.formPromise;
|
||||
if (response.twoFactor) {
|
||||
if (this.onSuccessfulLoginTwoFactorNavigate != null) {
|
||||
@@ -183,6 +183,9 @@ export class SsoComponent {
|
||||
}
|
||||
} catch (e) {
|
||||
this.logService.error(e);
|
||||
if (e.message === 'Unable to reach crypto agent') {
|
||||
this.platformUtilsService.showToast('error', null, this.i18nService.t('ssoCryptoAgentUnavailable'));
|
||||
}
|
||||
}
|
||||
this.loggingIn = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user