From 50a3f89b01dcb7d3c2de6813273b530d63bde0e5 Mon Sep 17 00:00:00 2001 From: chenpei Date: Sat, 4 Jul 2026 15:24:00 +0800 Subject: [PATCH] fix: persist public traffic cache rows --- lib/public-traffic-stats.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/public-traffic-stats.ts b/lib/public-traffic-stats.ts index 5e3e01b..f25437a 100644 --- a/lib/public-traffic-stats.ts +++ b/lib/public-traffic-stats.ts @@ -847,7 +847,8 @@ function persistentTrafficCacheEnabled() { } async function ensurePersistentTrafficCacheTable() { - if (persistentCacheTableEnsured || !persistentTrafficCacheEnabled()) return false + if (persistentCacheTableEnsured) return true + if (!persistentTrafficCacheEnabled()) return false const { prisma } = await import('./prisma')