sepe81 commented on code in PR #892:
URL: https://github.com/apache/struts/pull/892#discussion_r1514476089
##########
core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java:
##########
@@ -1026,9 +1030,12 @@ protected boolean isMultipartRequest(HttpServletRequest
request) {
String httpMethod = request.getMethod();
String contentType = request.getContentType();
- return REQUEST_POST_METHOD.equalsIgnoreCase(httpMethod) &&
- contentType != null &&
-
multipartValidationPattern.matcher(contentType.toLowerCase(Locale.ENGLISH)).matches();
+ boolean isPostRequest =
REQUEST_POST_METHOD.equalsIgnoreCase(httpMethod);
+ boolean isProperContentType = contentType != null &&
multipartValidationPattern.matcher(contentType.toLowerCase(Locale.ENGLISH)).matches();
+
+ LOG.debug("Validating if this is proper Multipart request. Request is
POST: {} and ContentType matches pattern ({}): {}",
Review Comment:
```suggestion
LOG.debug("Validating if this is a proper Multipart request. Request
is POST: {} and ContentType matches pattern ({}): {}",
```
##########
core/src/main/java/org/apache/struts2/dispatcher/Dispatcher.java:
##########
@@ -986,10 +986,12 @@ private void applyEncoding(HttpServletResponse response,
String encoding) {
public HttpServletRequest wrapRequest(HttpServletRequest request) throws
IOException {
// don't wrap more than once
if (request instanceof StrutsRequestWrapper) {
+ LOG.debug("Request already wrapped with {}",
StrutsRequestWrapper.class.getSimpleName());
Review Comment:
```suggestion
LOG.debug("Request already wrapped with: {}",
StrutsRequestWrapper.class.getSimpleName());
```
to be consistent with other logs from this PR
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]