fix(node): preserve optimize cleanup timestamp

This commit is contained in:
Gatefixer
2026-09-10 18:34:22 +00:00
parent 13f9dd630b
commit af17703268
6 changed files with 100 additions and 36 deletions
+2 -1
View File
@@ -26,7 +26,8 @@ const olderThan = new Date();
olderThan.setDate(olderThan.getDate() - 1));
tbl.optimize({cleanupOlderThan: olderThan});
// Delete all versions except the current version
// Delete versions committed before this point. Versions created by the
// optimize call itself are newer than the cutoff and will be retained.
tbl.optimize({cleanupOlderThan: new Date()});
```