fix: TypeScript compat for regex route param
All checks were successful
Build & Deploy to Staging / Build & Deploy to Staging (push) Successful in 10m15s

This commit is contained in:
Hoid 2026-03-02 21:11:10 +01:00
parent 56c7a87f3c
commit 01c214e054

View file

@ -143,7 +143,7 @@ app.get("/changelog", (_req, res) => res.redirect(301, "/changelog.html"));
// Blog routes // Blog routes
app.get("/blog", (_req, res) => res.redirect(301, "/blog.html")); app.get("/blog", (_req, res) => res.redirect(301, "/blog.html"));
app.get("/blog/:slug([^.]+)", (req, res) => res.redirect(301, `/blog/${req.params.slug}.html`)); app.get("/blog/:slug([^.]+)", (req, res) => res.redirect(301, `/blog/${(req.params as any).slug}.html`));
// Static files (landing page) // Static files (landing page)
app.use(express.static(path.join(__dirname, "../public"), { etag: true })); app.use(express.static(path.join(__dirname, "../public"), { etag: true }));