Changing DescendantOrSelf to DescendantOrSelf.First as it doesn't work with dynamics

This commit is contained in:
Jeavon Leopold
2014-06-09 08:41:29 +01:00
parent 40868d7cd2
commit e4837d1962

View File

@@ -86,11 +86,11 @@ namespace Umbraco.Web.Editors
timer.Start();
currentPage = currentPage.DescendantOrSelf(fromTypeAlias);
currentPage = currentPage.DescendantsOrSelf(fromTypeAlias).FirstOrDefault();
timer.Stop();
sb.AppendFormat(".DescendantOrSelf(\"{0}\")", fromTypeAlias);
sb.AppendFormat(".DescendantsOrSelf(\"{0}\").First()", fromTypeAlias);
}
// TYPE to return if filtered by type