mirror of
https://github.com/CJackHwang/ds2api.git
synced 2026-05-04 16:35:27 +08:00
fix: add missing Vercel rewrite rules for admin API routes
/admin/chat-history, /admin/proxies, /admin/dev/raw-samples, and /admin/dev/captures were falling through to the SPA fallback (/admin/index.html), causing "Unexpected token '<'" JSON parse errors on the frontend.
This commit is contained in:
16
vercel.json
16
vercel.json
@@ -81,6 +81,22 @@
|
||||
"source": "/admin/version",
|
||||
"destination": "/api/index"
|
||||
},
|
||||
{
|
||||
"source": "/admin/chat-history(.*)",
|
||||
"destination": "/api/index"
|
||||
},
|
||||
{
|
||||
"source": "/admin/proxies(.*)",
|
||||
"destination": "/api/index"
|
||||
},
|
||||
{
|
||||
"source": "/admin/dev/raw-samples/(.*)",
|
||||
"destination": "/api/index"
|
||||
},
|
||||
{
|
||||
"source": "/admin/dev/captures(.*)",
|
||||
"destination": "/api/index"
|
||||
},
|
||||
{
|
||||
"source": "/admin",
|
||||
"destination": "/admin/index.html"
|
||||
|
||||
Reference in New Issue
Block a user