Merge branch 'dev-v7' into dev-v7.8
# Conflicts: # src/SolutionInfo.cs # src/Umbraco.Core/Configuration/UmbracoVersion.cs # src/Umbraco.Core/UdiEntityType.cs # src/Umbraco.Core/Umbraco.Core.csproj # src/Umbraco.Web.UI/Umbraco.Web.UI.csproj # src/umbraco.cms/umbraco.cms.csproj
This commit is contained in:
@@ -86,7 +86,16 @@ namespace Umbraco.Web.Scheduling
|
||||
finally
|
||||
{
|
||||
if (tempContext != null)
|
||||
{
|
||||
// because we created an http context and assigned it to UmbracoContext,
|
||||
// the batched messenger does batch instructions, but since there is no
|
||||
// request, we need to explicitely tell it to flush the batch of instrs.
|
||||
var batchedMessenger = ServerMessengerResolver.Current.Messenger as BatchedDatabaseServerMessenger;
|
||||
if (batchedMessenger != null)
|
||||
batchedMessenger.FlushBatch();
|
||||
|
||||
tempContext.Dispose(); // nulls the ThreadStatic context
|
||||
}
|
||||
}
|
||||
|
||||
return true; // repeat
|
||||
|
||||
Reference in New Issue
Block a user