very minor whitespace fixes
Signed-off-by: Gavin King <gavin@hibernate.org>
This commit is contained in:
parent
522269e9a9
commit
8ea4d6a3c0
|
@ -4133,12 +4133,13 @@ public abstract class AbstractEntityPersister
|
||||||
if ( isUnsaved != null ) {
|
if ( isUnsaved != null ) {
|
||||||
if ( isUnsaved ) {
|
if ( isUnsaved ) {
|
||||||
final PersistenceContext persistenceContext;
|
final PersistenceContext persistenceContext;
|
||||||
if ( version == null && ( persistenceContext = session.getPersistenceContext() ).hasLoadContext()
|
if ( version == null
|
||||||
&& !persistenceContext.getLoadContexts().isLoadingFinished() ) {
|
&& ( persistenceContext = session.getPersistenceContext() ).hasLoadContext()
|
||||||
|
&& !persistenceContext.getLoadContexts().isLoadingFinished() ) {
|
||||||
// check if we're currently loading this entity instance, the version
|
// check if we're currently loading this entity instance, the version
|
||||||
// will be null but the entity cannot be considered transient
|
// will be null but the entity cannot be considered transient
|
||||||
final EntityHolder holder = persistenceContext
|
final EntityHolder holder =
|
||||||
.getEntityHolder( new EntityKey( id, this ) );
|
persistenceContext.getEntityHolder( new EntityKey( id, this ) );
|
||||||
if ( holder != null && holder.isEventuallyInitialized() && holder.getEntity() == entity ) {
|
if ( holder != null && holder.isEventuallyInitialized() && holder.getEntity() == entity ) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -4148,7 +4149,8 @@ public abstract class AbstractEntityPersister
|
||||||
final Boolean unsaved = identifierMapping.getUnsavedStrategy().isUnsaved( id );
|
final Boolean unsaved = identifierMapping.getUnsavedStrategy().isUnsaved( id );
|
||||||
if ( unsaved != null && !unsaved ) {
|
if ( unsaved != null && !unsaved ) {
|
||||||
throw new PropertyValueException(
|
throw new PropertyValueException(
|
||||||
"Detached entity with generated id '" + id + "' has an uninitialized version value '" + version + "'",
|
"Detached entity with generated id '" + id
|
||||||
|
+ "' has an uninitialized version value '" + version + "'",
|
||||||
getEntityName(),
|
getEntityName(),
|
||||||
getVersionColumnName()
|
getVersionColumnName()
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in New Issue