diff --git a/package.json b/package.json index 8e7814ff..ac6ef892 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,7 @@ "karma-firefox-launcher": "^2.0.0", "karma-mocha": "^2.0.0", "karma-sourcemap-loader": "^0.4.0", - "karma-webpack": "^5.0.0", + "karma-webpack": "5.0.0", "keypair": "^1.0.4", "linkinator": "^4.0.0", "mocha": "^9.2.2", diff --git a/src/auth/googleauth.ts b/src/auth/googleauth.ts index aca320ac..472ae789 100644 --- a/src/auth/googleauth.ts +++ b/src/auth/googleauth.ts @@ -343,7 +343,12 @@ export class GoogleAuth { let universeDomain = originalOrCamelOptions(this.clientOptions).get( 'universe_domain' ); - universeDomain ??= (await this.getClient()).universeDomain; + try { + universeDomain ??= (await this.getClient()).universeDomain; + } catch { + // client or ADC is not available + universeDomain ??= DEFAULT_UNIVERSE; + } return universeDomain; }