dexie 4.4.2 → 4.4.4
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/README.md +8 -0
- package/dist/dexie.d.ts +2 -2
- package/dist/dexie.js +10 -9
- package/dist/dexie.js.map +1 -1
- package/dist/dexie.min.js +1 -1
- package/dist/dexie.min.js.map +1 -1
- package/dist/dexie.mjs +10 -9
- package/dist/dexie.mjs.map +1 -1
- package/dist/modern/dexie.min.mjs +1 -1
- package/dist/modern/dexie.min.mjs.map +1 -1
- package/dist/modern/dexie.mjs +10 -9
- package/dist/modern/dexie.mjs.map +1 -1
- package/package.json +1 -1
package/dist/modern/dexie.mjs
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*
|
|
5
5
|
* By David Fahlander, david.fahlander@gmail.com
|
|
6
6
|
*
|
|
7
|
-
* Version 4.4.
|
|
7
|
+
* Version 4.4.4, Tue Jun 16 2026
|
|
8
8
|
*
|
|
9
9
|
* https://dexie.org
|
|
10
10
|
*
|
|
@@ -147,8 +147,11 @@ function setByKeyPath(obj, keyPath, value) {
|
|
|
147
147
|
obj[currentKeyPath] = value;
|
|
148
148
|
else {
|
|
149
149
|
var innerObj = obj[currentKeyPath];
|
|
150
|
-
if (!innerObj || !hasOwn(obj, currentKeyPath))
|
|
150
|
+
if (!innerObj || !hasOwn(obj, currentKeyPath)) {
|
|
151
|
+
if (value === undefined)
|
|
152
|
+
return;
|
|
151
153
|
innerObj = obj[currentKeyPath] = {};
|
|
154
|
+
}
|
|
152
155
|
setByKeyPath(innerObj, remainingKeyPath, value);
|
|
153
156
|
}
|
|
154
157
|
}
|
|
@@ -1166,7 +1169,7 @@ function tempTransaction(db, mode, storeNames, fn) {
|
|
|
1166
1169
|
}
|
|
1167
1170
|
}
|
|
1168
1171
|
|
|
1169
|
-
const DEXIE_VERSION = '4.4.
|
|
1172
|
+
const DEXIE_VERSION = '4.4.4';
|
|
1170
1173
|
const maxString = String.fromCharCode(65535);
|
|
1171
1174
|
const minKey = -Infinity;
|
|
1172
1175
|
const INVALID_KEY_ARGUMENT = 'Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.';
|
|
@@ -2026,7 +2029,7 @@ class Collection {
|
|
|
2026
2029
|
return cmp(aVal, bVal) * order;
|
|
2027
2030
|
}
|
|
2028
2031
|
return this.toArray(function (a) {
|
|
2029
|
-
return a.sort(sorter);
|
|
2032
|
+
return a.slice().sort(sorter);
|
|
2030
2033
|
}).then(cb);
|
|
2031
2034
|
}
|
|
2032
2035
|
toArray(cb) {
|
|
@@ -5590,9 +5593,6 @@ const cacheMiddleware = {
|
|
|
5590
5593
|
}
|
|
5591
5594
|
Object.freeze(result);
|
|
5592
5595
|
}
|
|
5593
|
-
else {
|
|
5594
|
-
res.result = deepClone(result);
|
|
5595
|
-
}
|
|
5596
5596
|
return res;
|
|
5597
5597
|
})
|
|
5598
5598
|
.catch((error) => {
|
|
@@ -5629,8 +5629,9 @@ const cacheMiddleware = {
|
|
|
5629
5629
|
}
|
|
5630
5630
|
subscribeToCacheEntry(cacheEntry, container, requery, signal);
|
|
5631
5631
|
return cacheEntry.promise.then((res) => {
|
|
5632
|
+
const result = applyOptimisticOps(res.result, req, tblCache?.optimisticOps, downTable, cacheEntry, freezeResults);
|
|
5632
5633
|
return {
|
|
5633
|
-
result:
|
|
5634
|
+
result: freezeResults ? result : deepClone(result),
|
|
5634
5635
|
};
|
|
5635
5636
|
});
|
|
5636
5637
|
},
|
|
@@ -6108,7 +6109,7 @@ function liveQuery(querier) {
|
|
|
6108
6109
|
};
|
|
6109
6110
|
const ret = execute(ctx);
|
|
6110
6111
|
if (!startedListening) {
|
|
6111
|
-
globalEvents(
|
|
6112
|
+
globalEvents.storagemutated.subscribe(mutationListener);
|
|
6112
6113
|
startedListening = true;
|
|
6113
6114
|
}
|
|
6114
6115
|
Promise.resolve(ret).then((result) => {
|