Update strip-nils to only strip nils, not empty strings, maps, etc #78
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm not sure if this is considered a bug, but it has recently caught us by surprise. If it's not a bug then
:strip-nils
option seems misnamed as it is more of astrip-empties
, removing empty strings, maps, vectors, etc.This change obviously potentially breaks backwards compatibility so I'm not sure if you'd want to include it as is (and whether you'd still want to support some strip-empties variant), but it does currently feel like a bug as the behaviour doesn't match what's implied by the name of the option, it's description or the intent of the original PR.
Thanks for your time and for all the wonderful metosin libraries 😄