修复bug

This commit is contained in:
hero920103 committed 2026-10-19 17:34:11 +08:00
1 parent 1850ac640e
commit 892ba5886d
20 files changed
+1078 -178

No files matched your search

+3 -1
View File
@@ -75,7 +75,9 @@ func RegisterPlatformSPA(spaDir string, hosts ...string) {
return
}
// SPA fallback:未知路径(hash 路由直接访问 /xxx/yyy)回 index.html
// SPA fallback:未知路径(hash 路由直接访问 /xxx/yyy)回 index.html。
// 标记一下,避免安全探针过滤器把「兜底返回首页」误判成敏感文件泄露。
ctx.Input.SetData("spa_fallback", true)
http.ServeFile(ctx.ResponseWriter, ctx.Request, spaDir+"/index.html")
})
}