mirror of
https://github.com/bitwarden/browser
synced 2025-12-21 02:33:46 +00:00
[AC-1562] Added region custom field to PayPal add credits (#5897)
* Added config service func for getting cloud region * Updated to use `buildServerConfig`
This commit is contained in:
@@ -63,6 +63,11 @@ export class ConfigService implements ConfigServiceAbstraction {
|
||||
return await this.getFeatureFlag(key, defaultValue);
|
||||
}
|
||||
|
||||
async getCloudRegion(defaultValue = "US"): Promise<string> {
|
||||
const serverConfig = await this.buildServerConfig();
|
||||
return serverConfig.environment?.cloudRegion ?? defaultValue;
|
||||
}
|
||||
|
||||
private async getFeatureFlag<T>(key: FeatureFlag, defaultValue: T): Promise<T> {
|
||||
const serverConfig = await this.buildServerConfig();
|
||||
if (
|
||||
|
||||
Reference in New Issue
Block a user