diff --git a/src/Orchard.Web/Themes/TheAdmin/Views/Menu.cshtml b/src/Orchard.Web/Themes/TheAdmin/Views/Menu.cshtml index 88091e6a6..2a942f332 100644 --- a/src/Orchard.Web/Themes/TheAdmin/Views/Menu.cshtml +++ b/src/Orchard.Web/Themes/TheAdmin/Views/Menu.cshtml @@ -39,6 +39,11 @@ : Html.Link(sectionHeaderText, (string)firstOfTheSecond.Href, new { @class = itemClassName }); } else { + // if the header isn't linked and there are no children there's no reason for this item in the menu other than to look pretty + if (secondLevelMenuItems.Count() == 0) { + continue; + } + sectionHeaderMarkup = HasText(itemId) ? new HtmlString(string.Format(@"{0}", Html.Encode(sectionHeaderText), Html.Encode(itemClassName), Html.Encode(itemId))) : new HtmlString(string.Format(@"{0}", Html.Encode(sectionHeaderText), Html.Encode(itemClassName)));