|
@@ -281,9 +281,10 @@ class BankClient {
|
|
|
if (!existing) {
|
|
if (!existing) {
|
|
|
throw new Error('missing contact with id ' + contactId);
|
|
throw new Error('missing contact with id ' + contactId);
|
|
|
}
|
|
}
|
|
|
|
|
+ const existingData = existing.getData();
|
|
|
const newProps = util_1.mergeDeep({}, newProperties);
|
|
const newProps = util_1.mergeDeep({}, newProperties);
|
|
|
delete newProps.id;
|
|
delete newProps.id;
|
|
|
- const newItem = util_1.mergeDeep(existing, newProps);
|
|
|
|
|
|
|
+ const newItem = util_1.mergeDeep(existingData, newProps);
|
|
|
delete newItem.hash;
|
|
delete newItem.hash;
|
|
|
const newItemHash = yield this.uploadSlimJSON(newItem);
|
|
const newItemHash = yield this.uploadSlimJSON(newItem);
|
|
|
yield this.appendPrivate(peerId, '📇', newItemHash, existing.hash);
|
|
yield this.appendPrivate(peerId, '📇', newItemHash, existing.hash);
|