With WebDataBinder, the empty value of Boolean is not Null but FALSE [SPR-17513] #22045
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
status: declined
A suggestion or change that we don't feel we should currently apply
yoshikawaa opened SPR-17513 and commented
With WebDataBinder, why the empty value of Boolean is not Null but FALSE ?
Form backing bean
Request Parameter
"_" prefixed value is converted to empty value in WebDataBinder#getEmptyValue .
If we use 3 pattern value (TRUE, FALSE, Null(=default)), it may becomes a problem.
Because the result are different when explicitly sending finished= and when implicit _finished= is sent.
Thanks.
Affects: 4.3.20, 5.1.2
Reference URL: https://github.com/spring-projects/spring-framework/blob/v5.1.2.RELEASE/spring-web/src/main/java/org/springframework/web/bind/WebDataBinder.java#L282-L285
The text was updated successfully, but these errors were encountered: