Add api parsing special case for send.bitwarden.com (#258)

This commit is contained in:
Matt Gibson 2021-03-16 14:19:51 -05:00 committed by GitHub
parent 576c020579
commit 73f358a09d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -99,7 +99,9 @@ export class SendReceiveCommand extends DownloadCommand {
}
private getApiUrl(url: URL) {
if (url.origin === this.apiService.apiBaseUrl) {
if (url.origin === 'https://send.bitwarden.com') {
return 'https://vault.bitwarden.com/api';
} else if (url.origin === this.apiService.apiBaseUrl) {
return url.origin;
} else if (this.platformUtilsService.isDev() && url.origin === this.environmentService.getWebVaultUrl()) {
return this.apiService.apiBaseUrl;