Skip to content

Commit 4c2c223

Browse files
Revert more exactly the auto flush change
1 parent 5f595e1 commit 4c2c223

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/NHibernate/Impl/SessionImpl.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -893,7 +893,7 @@ public void Delete(string entityName, object child, bool isCascadeDeleteEnabled,
893893
}
894894

895895
/// <inheritdoc/>
896-
public bool AutoFlushSuspended => _suspendAutoFlushCount > 0;
896+
public bool AutoFlushSuspended => _suspendAutoFlushCount != 0;
897897

898898
/// <inheritdoc/>
899899
public IDisposable SuspendAutoFlush()
@@ -915,7 +915,7 @@ public void Dispose()
915915
{
916916
if (_session == null)
917917
throw new ObjectDisposedException("The auto-flush suspension helper has been disposed already");
918-
_session._suspendAutoFlushCount --;
918+
_session._suspendAutoFlushCount--;
919919
_session = null;
920920
}
921921
}

0 commit comments

Comments
 (0)