Skip to content

Commit d52df3a

Browse files
committed
HHH-19031 Loading an Entity a second time when it contains an embedded object causes IllegalArgumentException
1 parent 5b0b799 commit d52df3a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hibernate-core/src/main/java/org/hibernate/sql/results/graph/embeddable/internal/NonAggregatedIdentifierMappingInitializer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ private void resolveInstanceSubInitializers(Object instance, RowProcessingState
318318
for ( int i = 0; i < subInitializersForResolveFromInitialized.length; i++ ) {
319319
final Initializer<InitializerData> initializer = subInitializersForResolveFromInitialized[i];
320320
if ( initializer != null ) {
321-
final Object subInstance = virtualIdEmbeddable.getValue( instance, i );
321+
final Object subInstance = representationEmbeddable.getValue( instance, i );
322322
if ( subInstance == LazyPropertyInitializer.UNFETCHED_PROPERTY ) {
323323
// Go through the normal initializer process
324324
initializer.resolveKey( rowProcessingState );

0 commit comments

Comments
 (0)