1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-17 16:53:34 +00:00

[PM-2594] Replacing hardcoded cloud vault urls based on region obtained from ConfigService (#5629)

* [PM-2594] Added property "CloudVault" to EnvironmentServerConfigData and EnvironmentServerConfigResponse

* [PM-2594] Replaced hardcoded vault urls with value obtained from ConfigService

* [PM-2594] Renamed EnvironmentServerConfigResponse.cloudVault to cloudWebVault

* [PM-2594] Updated unit test with new property "cloudWebVault"

* [PM-2594] Added methods to get and set CloudWebVaultUrl on EnvironmentService. Configured ConfigurationService to set value based on cloudVaultRegion

* [PM-2594] Added JSDOC comments to methods getCloudWebVaultUrl and setCloudWebVaultUrl

* [PM-2594] Renamed EnvironmentServerConfigData.cloudVaultRegion to cloudRegion

* [PM-2594] Fixed unit test
This commit is contained in:
Rui Tomé
2023-07-03 21:43:22 +01:00
committed by GitHub
parent b0d7a71b38
commit db2427e05c
10 changed files with 59 additions and 5 deletions

View File

@@ -1,5 +1,6 @@
import { Jsonify } from "type-fest";
import { Region } from "../../abstractions/environment.service";
import {
ServerConfigResponse,
ThirdPartyServerConfigResponse,
@@ -50,6 +51,7 @@ export class ThirdPartyServerConfigData {
}
export class EnvironmentServerConfigData {
cloudRegion: Region;
vault: string;
api: string;
identity: string;
@@ -57,6 +59,7 @@ export class EnvironmentServerConfigData {
sso: string;
constructor(response: Partial<EnvironmentServerConfigResponse>) {
this.cloudRegion = response.cloudRegion;
this.vault = response.vault;
this.api = response.api;
this.identity = response.identity;