You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bug #59501 [Serializer] [ObjectNormalizer] Filter int when using FILTER_BOOL (DjordyKoert)
This PR was submitted for the 7.2 branch but it was squashed and merged into the 7.1 branch instead.
Discussion
----------
[Serializer] [ObjectNormalizer] Filter int when using FILTER_BOOL
| Q | A
| ------------- | ---
| Branch? | 7.2
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Issues | Fix ...
| License | MIT
Improves on #57541 to also allow numeric values `1` and `0` with `FILTER_BOOL => true`
Currently attempting to use the Serializer component to deserialize to deserialize a `1` or `0` result in the following error:
```
The type of the "booleanProperty" attribute for class "App\MyDTO" must be one of "bool" ("int" given).
```
Commits
-------
5288eba [Serializer] [ObjectNormalizer] Filter int when using FILTER_BOOL
0 commit comments