HHH-10993 : NPE when Lazy loading collection without transaction for bytecode enhanced entitie
(cherry picked from commit 2c553f3290
)
This commit is contained in:
parent
43134abdd0
commit
f8243a6007
|
@ -335,12 +335,15 @@ public abstract class AbstractEntityEntry implements Serializable, EntityEntry {
|
|||
|
||||
@Override
|
||||
public void overwriteLoadedStateCollectionValue(String propertyName, PersistentCollection collection) {
|
||||
// nothing to do if status is READ_ONLY
|
||||
if ( getStatus() != Status.READ_ONLY ) {
|
||||
assert propertyName != null;
|
||||
assert loadedState != null;
|
||||
|
||||
final int propertyIndex = ( (UniqueKeyLoadable) persister ).getPropertyIndex( propertyName );
|
||||
loadedState[propertyIndex] = collection;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean requiresDirtyCheck(Object entity) {
|
||||
|
|
Loading…
Reference in New Issue