@omegup/msync 0.0.83 → 0.0.84
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/index.esm.js +3 -1
- package/index.js +3 -1
- package/package.json +1 -1
package/index.esm.js
CHANGED
|
@@ -258,8 +258,10 @@ const $pushDict = (key, value) => $accumulator(function () {
|
|
|
258
258
|
], function (ra, k, v, old) {
|
|
259
259
|
let a = { ...ra };
|
|
260
260
|
const equal = (a, b) => {
|
|
261
|
-
if (
|
|
261
|
+
if (!a || !b)
|
|
262
262
|
return a === b;
|
|
263
|
+
if ([a, b].some(a => Object.getPrototypeOf(a) != Object.prototype))
|
|
264
|
+
return a.valueOf() === b.valueOf();
|
|
263
265
|
const keys = Object.keys(a);
|
|
264
266
|
return keys.length === Object.keys(b).length && keys.every(k => equal(a[k], b[k]));
|
|
265
267
|
};
|
package/index.js
CHANGED
|
@@ -260,8 +260,10 @@ const $pushDict = (key, value) => $accumulator(function () {
|
|
|
260
260
|
], function (ra, k, v, old) {
|
|
261
261
|
let a = { ...ra };
|
|
262
262
|
const equal = (a, b) => {
|
|
263
|
-
if (
|
|
263
|
+
if (!a || !b)
|
|
264
264
|
return a === b;
|
|
265
|
+
if ([a, b].some(a => Object.getPrototypeOf(a) != Object.prototype))
|
|
266
|
+
return a.valueOf() === b.valueOf();
|
|
265
267
|
const keys = Object.keys(a);
|
|
266
268
|
return keys.length === Object.keys(b).length && keys.every(k => equal(a[k], b[k]));
|
|
267
269
|
};
|