fixes list view ancestor check fix

This commit is contained in:
Stephan
2015-10-29 12:19:54 +01:00
parent fbc08d66f1
commit da85e4eb28

View File

@@ -125,7 +125,11 @@ namespace Umbraco.Web.Models.Mapping
{
//it's new so it doesn't have a path, so we need to look this up by it's parent + ancestors
var parent = content.Parent();
if (parent.ContentType.IsContainer)
if (parent == null)
{
display.IsChildOfListView = false;
}
else if (parent.ContentType.IsContainer)
{
display.IsChildOfListView = true;
}