Correcting merge issues.

Fixing reset of published state in ContentRepository.
Correcting Querying tests after spacing has changed a bit.
This commit is contained in:
Morten Christensen
2012-12-21 09:45:34 -01:00
parent d816ac1125
commit 39e2314102
8 changed files with 54 additions and 37 deletions

View File

@@ -370,6 +370,18 @@ namespace Umbraco.Core.Models
}
}
/// <summary>
/// Checks whether an <see cref="IContent"/> item has any published versions
/// </summary>
/// <param name="content"></param>
/// <returns>True if the content has any published versiom otherwise False</returns>
public static bool HasPublishedVersion(this IContent content)
{
if (content.HasIdentity == false)
return false;
return ApplicationContext.Current.Services.ContentService.HasPublishedVersion(content.Id);
}
/// <summary>
/// Creates the xml representation for the <see cref="IContent"/> object