1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-06 00:13:28 +00:00

Fixed from json conversion for encyrpted key (#15536)

This commit is contained in:
SmithThe4th
2025-07-09 13:24:58 -04:00
committed by GitHub
parent 09fb74679d
commit b62f6c7eb5

View File

@@ -45,7 +45,8 @@ export class AttachmentView implements View {
static fromJSON(obj: Partial<Jsonify<AttachmentView>>): 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 });
}
/**