Skip to content

Commit

Permalink
resolve eslint error
Browse files Browse the repository at this point in the history
  • Loading branch information
rr-bw committed Oct 26, 2023

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 8d6eee5 commit 4d32a4a
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions libs/common/src/platform/services/environment.service.ts
Original file line number Diff line number Diff line change
@@ -288,17 +288,18 @@ export class EnvironmentService implements EnvironmentServiceAbstraction {
async getHost(userId?: string) {
const region = await this.getRegion(userId ? userId : null);

let envUrls;

switch (region) {
case Region.US:
return RegionDomain.US;
case Region.EU:
return RegionDomain.EU;
default:
// self-hosted host
envUrls = await this.stateService.getEnvironmentUrls(userId ? { userId: userId } : null);
default: {
// Environment is self-hosted
const envUrls = await this.stateService.getEnvironmentUrls(
userId ? { userId: userId } : null
);
return Utils.getHost(envUrls.webVault || envUrls.base);
}
}
}

0 comments on commit 4d32a4a

Please sign in to comment.