chore: upgrade Express 4 → 5 and fix wildcard route for path-to-regexp v8 (closes #54)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+1
-1
@@ -189,7 +189,7 @@ const spaLimiter = rateLimit({
|
||||
// --------------------------------------------------------
|
||||
// SPA Fallback: Alle nicht-API-Routen → index.html
|
||||
// --------------------------------------------------------
|
||||
app.get('*', spaLimiter, (req, res) => {
|
||||
app.get('/{*path}', spaLimiter, (req, res) => {
|
||||
if (req.path.startsWith('/api/')) {
|
||||
return res.status(404).json({ error: 'Nicht gefunden.', code: 404 });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user