mirror of
https://github.com/bitwarden/browser
synced 2025-12-14 15:23:33 +00:00
make sure org key exists for collection add/edit
This commit is contained in:
2
jslib
2
jslib
Submodule jslib updated: 773c51901f...2d612b07de
@@ -103,6 +103,10 @@ export class CollectionAddEditComponent implements OnInit {
|
||||
}
|
||||
|
||||
async submit() {
|
||||
if (this.orgKey == null) {
|
||||
throw new Error('No encryption key for this organization.');
|
||||
}
|
||||
|
||||
const request = new CollectionRequest();
|
||||
request.name = (await this.cryptoService.encrypt(this.name, this.orgKey)).encryptedString;
|
||||
request.groups = this.groups.filter((g) => (g as any).checked && !g.accessAll)
|
||||
|
||||
Reference in New Issue
Block a user