From ad80b94e14591651e75ab1ff312b566865ef8155 Mon Sep 17 00:00:00 2001 From: rstoyanchev Date: Thu, 3 Aug 2023 15:11:08 +0300 Subject: [PATCH] Allow BindParam on a field See gh-30947 --- .../java/org/springframework/web/bind/annotation/BindParam.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-web/src/main/java/org/springframework/web/bind/annotation/BindParam.java b/spring-web/src/main/java/org/springframework/web/bind/annotation/BindParam.java index 31fde117d44..569ce72b6aa 100644 --- a/spring-web/src/main/java/org/springframework/web/bind/annotation/BindParam.java +++ b/spring-web/src/main/java/org/springframework/web/bind/annotation/BindParam.java @@ -31,7 +31,7 @@ import java.lang.annotation.Target; * @since 6.1 * @see org.springframework.web.bind.WebDataBinder#construct */ -@Target(ElementType.PARAMETER) +@Target({ElementType.PARAMETER, ElementType.FIELD}) @Retention(RetentionPolicy.RUNTIME) @Documented public @interface BindParam {