From 03a0a3c50ba7855d395ef9cdf53f2118e14ef351 Mon Sep 17 00:00:00 2001 From: "Henry Q. Dineen" Date: Thu, 7 May 2026 23:24:58 -0400 Subject: [PATCH] [docs] Fix RSS/Atom feed dates all showing the build date The regex used to extract dates from blog post paths had a leading `\/`, but fumadocs normalizes paths without a leading slash (e.g. `2024-04-16-Release-v0.6.1`). Every match failed, so all posts fell back to `new Date()` and showed the build timestamp instead of their actual publish date. Co-Authored-By: Claude Sonnet 4.6 (1M context) --- packages/docs/src/lib/rss.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/docs/src/lib/rss.ts b/packages/docs/src/lib/rss.ts index f7e2ecea9..7062501e8 100644 --- a/packages/docs/src/lib/rss.ts +++ b/packages/docs/src/lib/rss.ts @@ -62,7 +62,7 @@ async function createFeed(): Promise { const url = `${baseUrl}/blog/${page.data.slug}`; // Parse date from the path (format: YYYY-MM-DD-title) - const pathMatch = page.path.match(/\/(\d{4}-\d{2}-\d{2})/); + const pathMatch = page.path.match(/^(\d{4}-\d{2}-\d{2})/); const dateStr = pathMatch?.[1]; const date = dateStr ? new Date(dateStr) : new Date();