mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-09-21 05:09:13 +00:00
SPR-6206 - When looking up methods with @RequestMapping annotation, unannotated bridge methods are included
git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@2111 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
+2
-2
@@ -77,7 +77,7 @@ public class HandlerMethodResolver {
|
||||
ReflectionUtils.doWithMethods(currentHandlerType, new ReflectionUtils.MethodCallback() {
|
||||
public void doWith(Method method) {
|
||||
Method specificMethod = ClassUtils.getMostSpecificMethod(method, currentHandlerType);
|
||||
if (isHandlerMethod(specificMethod)) {
|
||||
if (isHandlerMethod(method)) {
|
||||
handlerMethods.add(specificMethod);
|
||||
}
|
||||
else if (method.isAnnotationPresent(InitBinder.class)) {
|
||||
@@ -99,7 +99,7 @@ public class HandlerMethodResolver {
|
||||
}
|
||||
|
||||
protected boolean isHandlerMethod(Method method) {
|
||||
return AnnotationUtils.findAnnotation(method, RequestMapping.class) != null;
|
||||
return method.isAnnotationPresent(RequestMapping.class);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user