mirror of
https://github.com/bitwarden/browser.git
synced 2024-12-27 17:18:04 +01:00
rename to bitwardenContainerService
This commit is contained in:
parent
808e74bcfb
commit
ce628ba1db
@ -117,13 +117,13 @@ class Cipher extends Domain {
|
|||||||
model.login = await this.login.decrypt(this.organizationId);
|
model.login = await this.login.decrypt(this.organizationId);
|
||||||
model.subTitle = model.login.username;
|
model.subTitle = model.login.username;
|
||||||
if (model.login.uri) {
|
if (model.login.uri) {
|
||||||
const containerService = (window as any).BitwardenContainerService;
|
const containerService = (window as any).bitwardenContainerService;
|
||||||
if (containerService) {
|
if (containerService) {
|
||||||
const platformUtilsService: PlatformUtilsService =
|
const platformUtilsService: PlatformUtilsService =
|
||||||
containerService.getPlatformUtilsService();
|
containerService.getPlatformUtilsService();
|
||||||
model.login.domain = platformUtilsService.getDomain(model.login.uri);
|
model.login.domain = platformUtilsService.getDomain(model.login.uri);
|
||||||
} else {
|
} else {
|
||||||
throw new Error('window.BitwardenContainerService not initialized.');
|
throw new Error('window.bitwardenContainerService not initialized.');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -93,11 +93,11 @@ class CipherString {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let cryptoService: CryptoService;
|
let cryptoService: CryptoService;
|
||||||
const containerService = (window as any).BitwardenContainerService;
|
const containerService = (window as any).bitwardenContainerService;
|
||||||
if (containerService) {
|
if (containerService) {
|
||||||
cryptoService = containerService.getCryptoService();
|
cryptoService = containerService.getCryptoService();
|
||||||
} else {
|
} else {
|
||||||
throw new Error('window.BitwardenContainerService not initialized.');
|
throw new Error('window.bitwardenContainerService not initialized.');
|
||||||
}
|
}
|
||||||
|
|
||||||
return cryptoService.getOrgKey(orgId).then((orgKey: any) => {
|
return cryptoService.getOrgKey(orgId).then((orgKey: any) => {
|
||||||
|
@ -7,8 +7,8 @@ export class ContainerService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
attachToWindow(win: any) {
|
attachToWindow(win: any) {
|
||||||
if (!win.BitwardenContainerService) {
|
if (!win.bitwardenContainerService) {
|
||||||
win.BitwardenContainerService = this;
|
win.bitwardenContainerService = this;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user