fix: 增加接口判断

This commit is contained in:
TS-QD1 2025-06-17 11:53:21 +08:00
parent 3a48ec2916
commit 7fd71ca8aa

View File

@ -104,7 +104,7 @@ public class ResponseAdvice {
}
String contentType = request.getContentType();
String requestURI = request.getRequestURI();
if ((requestURI.contains("/app/")) || (contentType != null && contentType.contains(MediaType.APPLICATION_JSON_VALUE))) {
if ((requestURI.contains("/api/") || requestURI.contains("/app/")) || (contentType != null && contentType.contains(MediaType.APPLICATION_JSON_VALUE))) {
response.setCharacterEncoding(ISystemConstant.CHARSET_UTF8);
response.setContentType(MediaType.APPLICATION_JSON_VALUE);
response.setStatus(HttpStatus.BAD_REQUEST.value());