Skip to content

Commit

Permalink
Merge pull request #23839 from jperezdelafuente/fix-issue-23753
Browse files Browse the repository at this point in the history
Using getter in equals() methods to be Hibernate-safe
  • Loading branch information
DanielFran authored Oct 13, 2023
2 parents 1680c9c + 224600d commit ff071d7
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ _%>
return false;
}
<%_ if (!embedded) { _%>
return <%= primaryKey.name %> != null && <%= primaryKey.name %>.equals(((<%= persistClass %>) o).<%= primaryKey.name %>);
return get<%= primaryKey.nameCapitalized %>() != null && get<%= primaryKey.nameCapitalized %>().equals(((<%= persistClass %>) o).get<%= primaryKey.nameCapitalized %>());
<%_ } else { _%>
return false;
<%_ } _%>
Expand Down

0 comments on commit ff071d7

Please sign in to comment.