Skip to content

#3747 Fix empty if-block when NullValueMappingStrategy is RETURN_DEFAULT and target is immutable#3749

Closed
Hypnagokali wants to merge 1 commit intomapstruct:mainfrom
Hypnagokali:#3747
Closed

#3747 Fix empty if-block when NullValueMappingStrategy is RETURN_DEFAULT and target is immutable#3749
Hypnagokali wants to merge 1 commit intomapstruct:mainfrom
Hypnagokali:#3747

Conversation

@Hypnagokali
Copy link
Contributor

Fixes #3747

Problem:
The BeanMappingMethod template always creates the if-block for the property mappings, even if the target only has constructor mappings.

The unit tests are green but when I run "mvnw install" I get an exception from the maven shade plugin. The exception disappears when I set the version to 3.2.1

@filiphr
Copy link
Member

filiphr commented Nov 3, 2024

Sorry I missed this @Hypnagokali and I already did #3758, so closing this in favor of that one. I also prefer the solution in my PR as it is slightly simpler then this PR.

@filiphr filiphr closed this Nov 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Redundant if condition in Java record mapping with RETURN_DEFAULT strategy

2 participants