|
@@ -162,7 +162,7 @@ public class RequestInvokeInterceptor extends OncePerRequestFilter {
|
|
// Servlet 规范规定如果调用了getInputStream()或getReader()方法,则getParameter*()方法的行为是未定义的
|
|
// Servlet 规范规定如果调用了getInputStream()或getReader()方法,则getParameter*()方法的行为是未定义的
|
|
// Tomcat、Jetty、Undertow容器均支持在调用getParameter*()方法后能正常调用getInputStream()方法
|
|
// Tomcat、Jetty、Undertow容器均支持在调用getParameter*()方法后能正常调用getInputStream()方法
|
|
this.parameters = request.getParameterMap();
|
|
this.parameters = request.getParameterMap();
|
|
- if (HttpUtils.isBodyMethod(request)) {
|
|
|
|
|
|
+ if (HttpUtils.hasBody(request)) {
|
|
try (InputStream input = request.getInputStream()) {
|
|
try (InputStream input = request.getInputStream()) {
|
|
if (input instanceof CachingInputStream) {
|
|
if (input instanceof CachingInputStream) {
|
|
this.bytes = ((CachingInputStream) input).bytes;
|
|
this.bytes = ((CachingInputStream) input).bytes;
|