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
That's a very good question actually... It does seem I specifically added this behavior, as per this commit. The commit doesn't mention any reason, nor are there any related issues around that time. When I think about it, I have to agree with you that the expected behavior for mapFrom should be to respect the ignoreNullProperties option.
Since this is a BC breaking change, I'm a bit reluctant to add this to the 1.x release though. As a solution for you right this moment, I'd suggest creating your own MapFrom operation, extend it from the library's and overwrite the setDestinationValue method. I know this isn't ideal, but it should work for now.
Hi, I'd like to know why this overwriten function:
In MapFrom.php
doesn't have this check from his parent:
In this case, when I use mapToObject, it won't skip null fields even I configured it in options by:
The text was updated successfully, but these errors were encountered: