From 8af5c9dcb39fcabb2a696c9928d4e849c34dca40 Mon Sep 17 00:00:00 2001 From: Gavin King Date: Fri, 12 Jan 2024 13:17:55 +0100 Subject: [PATCH] add a comment --- hibernate-core/src/main/java/org/hibernate/type/TypeHelper.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hibernate-core/src/main/java/org/hibernate/type/TypeHelper.java b/hibernate-core/src/main/java/org/hibernate/type/TypeHelper.java index d8407c7292..9223fff3a3 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/TypeHelper.java +++ b/hibernate-core/src/main/java/org/hibernate/type/TypeHelper.java @@ -191,6 +191,8 @@ public class TypeHelper { } else { final Type type = types[i]; + // AnyType is both a CompositeType and an AssociationType + // but here we want to treat it as an association if ( type.isAssociationType() ) { copied[i] = types[i].replace( currentOriginal, target[i], session, owner, copyCache, foreignKeyDirection ); }