diff --git a/libs/common/src/vault/models/view/attachment.view.ts b/libs/common/src/vault/models/view/attachment.view.ts index 57a1deaedb9..d943d21367d 100644 --- a/libs/common/src/vault/models/view/attachment.view.ts +++ b/libs/common/src/vault/models/view/attachment.view.ts @@ -45,7 +45,8 @@ export class AttachmentView implements View { static fromJSON(obj: Partial>): AttachmentView { const key = obj.key == null ? null : SymmetricCryptoKey.fromJSON(obj.key); - return Object.assign(new AttachmentView(), obj, { key: key }); + const encryptedKey = obj.encryptedKey == null ? undefined : new EncString(obj.encryptedKey); + return Object.assign(new AttachmentView(), obj, { key: key, encryptedKey: encryptedKey }); } /**