@acodeninja/persist 3.0.0-next.4 → 3.0.0-next.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
@@ -120,6 +120,14 @@ export default class StorageEngine {
|
|
120
120
|
const currentModel = await this.get(model.id);
|
121
121
|
|
122
122
|
await this._deleteModel(currentModel.id);
|
123
|
+
|
124
|
+
const currentIndex = this._getIndex(currentModel.constructor);
|
125
|
+
|
126
|
+
await this._putIndex(currentModel.constructor, _.omit(currentIndex, [currentModel.id]));
|
127
|
+
|
128
|
+
const currentSearchIndex = this._getSearchIndex(currentModel.constructor);
|
129
|
+
|
130
|
+
await this._putSearchIndex(currentModel.constructor, _.omit(currentSearchIndex, [currentModel.id]));
|
123
131
|
}
|
124
132
|
|
125
133
|
/**
|