NuCache: children as linked lists

This commit is contained in:
Stephan
2019-04-22 17:51:07 +02:00
parent 2270188668
commit 05c85bbce5
5 changed files with 227 additions and 187 deletions

View File

@@ -172,7 +172,11 @@ namespace Umbraco.Web
/// </summary>
/// <remarks>Culture is case-insensitive.</remarks>
public static bool HasCulture(this IPublishedContent content, string culture)
=> content.Cultures.Contains(culture ?? string.Empty);
=> content.Cultures.Contains(culture ?? string.Empty); // fixme oops?!
// fixme
public static bool IsInvariantOrHasCulture(this IPublishedContent content, string culture)
=> !content.ContentType.VariesByCulture() || content.Cultures.Contains(culture ?? "");
/// <summary>
/// Filters a sequence of <see cref="IPublishedContent"/> to return invariant items, and items that are published for the specified culture.