fix: 增加接口判断
This commit is contained in:
parent
3a48ec2916
commit
7fd71ca8aa
@ -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());
|
||||
|
Loading…
Reference in New Issue
Block a user