Skip to content

Commit 9cf5ca0

Browse files
committed
HHH-19952: Dynamic Type error fixed.
1 parent b4d5255 commit 9cf5ca0

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

hibernate-core/src/main/java/org/hibernate/boot/model/internal/CollectionBinder.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2898,10 +2898,16 @@ private static CollectionTableOverride findCollectionTableOverride(
28982898
return null;
28992899
}
29002900

2901+
// Get the class name - may be null for dynamic models (DynamicMap, DynamicModel)
2902+
final String className = persistentClass.getClassName();
2903+
if ( className == null ) {
2904+
return null;
2905+
}
2906+
29012907
// Get the ClassDetails from the models context
29022908
final var modelsContext = buildingContext.getBootstrapContext().getModelsContext();
29032909
final var entityClassDetails = modelsContext.getClassDetailsRegistry()
2904-
.resolveClassDetails( persistentClass.getClassName() );
2910+
.resolveClassDetails( className );
29052911

29062912
if ( entityClassDetails == null ) {
29072913
return null;

0 commit comments

Comments
 (0)