mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
SPR-5802 - NullPointerException when using @CookieValue annotation
This commit is contained in:
+4
-1
@@ -638,9 +638,12 @@ public class AnnotationMethodHandlerAdapter extends WebContentGenerator implemen
|
||||
if (Cookie.class.isAssignableFrom(paramType)) {
|
||||
return cookieValue;
|
||||
}
|
||||
else {
|
||||
else if (cookieValue != null) {
|
||||
return cookieValue.getValue();
|
||||
}
|
||||
else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user