This is an automated email from the ASF dual-hosted git repository. borinquenkid pushed a commit to branch 8.0.x-hibernate7 in repository https://gitbox.apache.org/repos/asf/grails-core.git
commit 8bd87389d07367a54890b61a9d8a7e522128802f Author: Walter Duque de Estrada <[email protected]> AuthorDate: Thu Feb 26 15:32:17 2026 -0600 Fix PMD issue in IdentityEnumType --- grails-data-hibernate7/core/PMD.md | 2 +- .../src/main/groovy/org/grails/orm/hibernate/cfg/IdentityEnumType.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/grails-data-hibernate7/core/PMD.md b/grails-data-hibernate7/core/PMD.md index 766887c49b..10998285c7 100644 --- a/grails-data-hibernate7/core/PMD.md +++ b/grails-data-hibernate7/core/PMD.md @@ -141,7 +141,7 @@ DataflowAnomalyAnalysis,org.grails.orm.hibernate.cfg.HibernateMappingContextConf CloseResource,org.grails.orm.hibernate.cfg.HibernateMappingContextConfiguration,290, CloseResource,org.grails.orm.hibernate.cfg.HibernateMappingContextConfiguration,315, AvoidCatchingThrowable,org.grails.orm.hibernate.cfg.HibernateMappingContextConfiguration,318,YES -CompareObjectsWithEquals,org.grails.orm.hibernate.cfg.IdentityEnumType,119, +CompareObjectsWithEquals,org.grails.orm.hibernate.cfg.IdentityEnumType,119,YES DataflowAnomalyAnalysis,org.grails.orm.hibernate.cfg.MappingCacheHolder,65, DataflowAnomalyAnalysis,org.grails.orm.hibernate.cfg.domainbinding.binder.ClassPropertiesBinder,72, DataflowAnomalyAnalysis,org.grails.orm.hibernate.cfg.domainbinding.binder.CollectionBinder,228, diff --git a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/IdentityEnumType.java b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/IdentityEnumType.java index 6624c9b225..6610b8b73a 100644 --- a/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/IdentityEnumType.java +++ b/grails-data-hibernate7/core/src/main/groovy/org/grails/orm/hibernate/cfg/IdentityEnumType.java @@ -116,7 +116,7 @@ public class IdentityEnumType implements UserType, ParameterizedType, Serializab @Override public boolean equals(Object o1, Object o2) throws HibernateException { - return o1 == o2; + return java.util.Objects.equals(o1, o2); } @Override
