HHH-16784 Fix type resolution for generic interface properties

This commit is contained in:
Marco Belladelli 2023-06-20 16:00:47 +02:00
parent e272e012d2
commit fd661534d7
1 changed files with 1 additions and 1 deletions

View File

@ -236,7 +236,7 @@ public class AttributeFactory {
switch ( typeContext.getValueClassification() ) {
case BASIC: {
Class returnedClass = typeContext.getJpaBindableType();
if ( returnedClass.isAssignableFrom( Object.class ) ) {
if ( returnedClass.isInterface() || returnedClass.isAssignableFrom( Object.class ) ) {
final SimpleValue simpleValue = (SimpleValue) typeContext.getHibernateValue();
if ( simpleValue.getTypeParameters() != null && typeContext.getAttributeMetadata()
.getOwnerType() instanceof EntityDomainType ) {