mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-06-09 19:47:39 +08:00
fix: 把原生 WS 与 SockJS 分路径,避免混淆
This commit is contained in:
@@ -175,7 +175,7 @@ public class SecurityConfig {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
} else if (!uri.startsWith("/api/auth") && !publicGet
|
} else if (!uri.startsWith("/api/auth") && !publicGet
|
||||||
&& !uri.startsWith("/api/ws") && !uri.startsWith("/api/sockjs") {
|
&& !uri.startsWith("/api/ws") && !uri.startsWith("/api/sockjs")) {
|
||||||
response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
|
response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
|
||||||
response.setContentType("application/json");
|
response.setContentType("application/json");
|
||||||
response.getWriter().write("{\"error\": \"Missing token\"}");
|
response.getWriter().write("{\"error\": \"Missing token\"}");
|
||||||
|
|||||||
Reference in New Issue
Block a user