fix(cleanup): restore usage history cutoff boundary

This commit is contained in:
Halil Tezcan KARABULUT
2026-05-29 23:08:34 +03:00
committed by diegosouzapw
parent 6123e482a9
commit 25741a7fb0
2 changed files with 34 additions and 1 deletions

View File

@@ -28,7 +28,6 @@ export async function cleanupQuotaSnapshots(): Promise<CleanupResult> {
const cutoffDate = new Date();
cutoffDate.setDate(cutoffDate.getDate() - retentionDays);
const cutoffISO = cutoffDate.toISOString();
const cutoffDateStr = cutoffISO.split("T")[0];
const result: CleanupResult = { deleted: 0, errors: 0 };
@@ -87,6 +86,7 @@ export async function cleanupUsageHistory(): Promise<CleanupResult> {
const cutoffDate = new Date();
cutoffDate.setDate(cutoffDate.getDate() - retentionDays);
const cutoffISO = cutoffDate.toISOString();
const cutoffDateStr = cutoffISO.split("T")[0];
const result: CleanupResult = { deleted: 0, errors: 0 };