From ceffc0589921eccc36d2feab57851ec47b08d8c0 Mon Sep 17 00:00:00 2001 From: Oliver Bryan Date: Fri, 6 Feb 2026 11:26:27 +0000 Subject: [PATCH] use .getTime() --- src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index 781f779..733d66e 100644 --- a/src/index.ts +++ b/src/index.ts @@ -27,7 +27,7 @@ app.get("/", async (c) => { const now = new Date(); const start = new Date(now.getFullYear(), 0, 0); - const diff = now - start; + const diff = now.getTime() - start.getTime(); const oneDay = 1000 * 60 * 60 * 24; const today = Math.floor(diff / oneDay) - 1;