ueberdb2 5.0.15 → 5.0.21

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/dist/index.js CHANGED
@@ -468,7 +468,13 @@ const Database$1 = class Database {
468
468
  ptr.obj = ptr.obj[ptr.prop];
469
469
  ptr.prop = sub[i];
470
470
  }
471
- ptr.obj[ptr.prop] = value;
471
+ // Delete the property if value is undefined. JSON.stringify() ignores such properties.
472
+ if (value == null) {
473
+ delete ptr.obj[ptr.prop];
474
+ }
475
+ else {
476
+ ptr.obj[ptr.prop] = value;
477
+ }
472
478
  }
473
479
  catch (err) {
474
480
  // this._setLocked() will not be called but it should still count as a write failure.
@@ -480,7 +486,7 @@ const Database$1 = class Database {
480
486
  p = this._setLocked(key, base.fullValue);
481
487
  }
482
488
  finally {
483
- this._unlock(key);
489
+ await this._unlock(key);
484
490
  }
485
491
  }
486
492
  finally {
@@ -1 +1 @@
1
- {"version":3,"file":"CacheAndBufferLayer.d.ts","sourceRoot":"","sources":["../../lib/CacheAndBufferLayer.ts"],"names":[],"mappings":"AAsCA;;GAEG;AACH,qBAAa,GAAG;IACd;;;;;;;OAOG;gBACS,QAAQ,KAAA,EAAE,SAAS,8BAAiB;IAMhD;;;OAGG;IACH,CAAC,MAAM,CAAC,QAAQ,CAAC;IAIjB;;;;OAIG;IACH,GAAG,CAAC,CAAC,KAAA,EAAE,KAAK,UAAO;IAWnB;;OAEG;IACH,GAAG,CAAC,CAAC,KAAA,EAAE,CAAC,KAAA;IAMR;;;;OAIG;IACH,QAAQ;CAST;AA+BD,eAAO,MAAM,QAAQ;;;;;;QAkJnB;;WAEG;;QAKH;;WAEG;;QAQH;;WAEG;;;QAmEH;;;WAGG;;QAWH;;WAEG;;QAMH;;WAEG;;;QA4DH;;WAEG;;QAqDH;;;;WAIG;;QAyBH;;WAEG;;;;CA0FJ,CAAC;AAoCF,eAAO,MAAM,kBAAkB;;CAE9B,CAAC"}
1
+ {"version":3,"file":"CacheAndBufferLayer.d.ts","sourceRoot":"","sources":["../../lib/CacheAndBufferLayer.ts"],"names":[],"mappings":"AAsCA;;GAEG;AACH,qBAAa,GAAG;IACd;;;;;;;OAOG;gBACS,QAAQ,KAAA,EAAE,SAAS,8BAAiB;IAMhD;;;OAGG;IACH,CAAC,MAAM,CAAC,QAAQ,CAAC;IAIjB;;;;OAIG;IACH,GAAG,CAAC,CAAC,KAAA,EAAE,KAAK,UAAO;IAWnB;;OAEG;IACH,GAAG,CAAC,CAAC,KAAA,EAAE,CAAC,KAAA;IAMR;;;;OAIG;IACH,QAAQ;CAST;AA+BD,eAAO,MAAM,QAAQ;;;;;;QAkJnB;;WAEG;;QAKH;;WAEG;;QAQH;;WAEG;;;QAmEH;;;WAGG;;QAWH;;WAEG;;QAMH;;WAEG;;;QA4DH;;WAEG;;QA0DH;;;;WAIG;;QAyBH;;WAEG;;;;CA0FJ,CAAC;AAoCF,eAAO,MAAM,kBAAkB;;CAE9B,CAAC"}
package/package.json CHANGED
@@ -65,7 +65,7 @@
65
65
  "url": "https://github.com/ether/ueberDB.git"
66
66
  },
67
67
  "main": "./dist/index.js",
68
- "version": "5.0.15",
68
+ "version": "5.0.21",
69
69
  "bugs": {
70
70
  "url": "https://github.com/ether/ueberDB/issues"
71
71
  },