@ztimson/utils 0.26.6 → 0.26.7

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.cjs CHANGED
@@ -483,7 +483,9 @@ ${opts.message || this.desc}`;
483
483
  if (((_a = persists.storage) == null ? void 0 : _a.database) != void 0) {
484
484
  persists.storage.createTable({ name: persists.key, key: this.key }).then((table) => {
485
485
  if (key) {
486
- table.set(this.get(key), key);
486
+ const value = this.get(key);
487
+ if (value != null) table.set(value, key);
488
+ else table.delete(key);
487
489
  } else {
488
490
  table.clear();
489
491
  this.all().forEach((row) => table.add(row));