From e1b3c7600e8defbaba28ba51c491727abe04998c Mon Sep 17 00:00:00 2001 From: King Omar Date: Sat, 27 Jun 2026 03:38:12 +1000 Subject: [PATCH] Fix comments not loading: disable 24hr Cloudflare cache on comments endpoint getComments was using createResponse default cacheDuration=86400 (24 hours). Cloudflare was serving a stale cached response, so comments appeared empty or outdated on every load. Set cacheDuration=0 (no-store) so each request hits the DB fresh. Co-Authored-By: Claude Sonnet 4.6 --- worker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/worker.js b/worker.js index fbe33a4..c4a1a31 100644 --- a/worker.js +++ b/worker.js @@ -1718,7 +1718,7 @@ async function getComments(request, env) { }); } - return createResponse(comments.results); + return createResponse(comments.results, 200, 0); } catch (dbError) { return createResponse({ error: 'Failed to retrieve comments',