Skip to content

Commit

Permalink
Merge pull request #1 from trackabout/mk/upgradeNhibernate552
Browse files Browse the repository at this point in the history
Fix: Regression from NHibernate 1.2 in flushing
  • Loading branch information
mjkent authored Oct 7, 2024
2 parents 39de4d9 + 76dd1bc commit 7b29b1d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/NHibernate/Async/Impl/SessionImpl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ public override async Task<bool> AutoFlushIfRequiredAsync(ISet<string> querySpac
cancellationToken.ThrowIfCancellationRequested();
using (BeginProcess())
{
if (!ConnectionManager.IsInActiveTransaction)
if (IsClosed)
{
// do not auto-flush while outside a transaction
return false;
Expand Down
2 changes: 1 addition & 1 deletion src/NHibernate/Impl/SessionImpl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ public override bool AutoFlushIfRequired(ISet<string> querySpaces)
{
using (BeginProcess())
{
if (!ConnectionManager.IsInActiveTransaction)
if (IsClosed)
{
// do not auto-flush while outside a transaction
return false;
Expand Down

0 comments on commit 7b29b1d

Please sign in to comment.