Polish "Reuse constant in DispatcherServlet"
Closes gh-1398
This commit is contained in:
@@ -267,8 +267,8 @@ public class DispatcherServlet extends FrameworkServlet {
|
||||
/**
|
||||
* Common prefix that DispatcherServlet's default strategy attributes start with.
|
||||
*/
|
||||
private static final String DEFAULT_STRATEGIES_PREFIX = "org.springframework.web.servlet";
|
||||
|
||||
private static final String DEFAULT_STRATEGIES_PREFIX = "org.springframework.web.servlet";
|
||||
|
||||
/** Additional logger to use when no mapped handler is found for a request. */
|
||||
protected static final Log pageNotFoundLogger = LogFactory.getLog(PAGE_NOT_FOUND_LOG_CATEGORY);
|
||||
|
||||
@@ -1352,7 +1352,7 @@ public class DispatcherServlet extends FrameworkServlet {
|
||||
Enumeration<?> attrNames = request.getAttributeNames();
|
||||
while (attrNames.hasMoreElements()) {
|
||||
String attrName = (String) attrNames.nextElement();
|
||||
if (this.cleanupAfterInclude || attrName.startsWith("org.springframework.web.servlet")) {
|
||||
if (this.cleanupAfterInclude || attrName.startsWith(DEFAULT_STRATEGIES_PREFIX)) {
|
||||
attrsToCheck.add(attrName);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user