Fixing another part of #U4-2186

This commit is contained in:
Morten Christensen
2013-06-27 10:56:45 +02:00
parent 0d5ec8bfd5
commit ccbb838cef
2 changed files with 4 additions and 11 deletions

View File

@@ -1455,11 +1455,10 @@ namespace Umbraco.Core.Services
var uow = _uowProvider.GetUnitOfWork();
using (var repository = _repositoryFactory.CreateContentRepository(uow))
{
//Only loop through content that was successfully published, was not already published and where the Published property has been updated
//NOTE The Publish with subpages-dialog was used more as a republish-type-thing, so we'll have to include PublishStatusType.SuccessAlreadyPublished
//in the updated-list, so the Published event is triggered with the expected set of pages and the xml is updated.
foreach (var item in publishedOutcome.Where(
x => x.Success
&& x.Result.StatusType != PublishStatusType.SuccessAlreadyPublished
&& ((ICanBeDirty)x.Result.ContentItem).IsPropertyDirty("Published")))
x => x.Success || x.Result.StatusType == PublishStatusType.SuccessAlreadyPublished))
{
item.Result.ContentItem.WriterId = userId;
repository.AddOrUpdate(item.Result.ContentItem);

View File

@@ -1,16 +1,10 @@
using System;
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using Umbraco.Core;
using Umbraco.Core.Events;
using Umbraco.Core.Models;
using Umbraco.Core.Publishing;
using Umbraco.Web.Cache;
using umbraco;
using umbraco.cms.businesslogic.web;
using umbraco.interfaces;
using umbraco.presentation.cache;
using UmbracoSettings = Umbraco.Core.Configuration.UmbracoSettings;
namespace Umbraco.Web.Strategies.Publishing
{