mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
#18808: Fixing ghost menu items when migrating from 1.4
Work Item: 18808
This commit is contained in:
@@ -171,8 +171,8 @@ namespace Orchard.Core.Navigation {
|
|||||||
|
|
||||||
// assign the Main Menu to all current menu items
|
// assign the Main Menu to all current menu items
|
||||||
foreach (var menuItem in _menuService.Get()) {
|
foreach (var menuItem in _menuService.Get()) {
|
||||||
// if they don't have a position, then they are not displayed
|
// if they don't have a position or a text, then they are not displayed
|
||||||
if(string.IsNullOrWhiteSpace(menuItem.MenuPosition)) {
|
if(string.IsNullOrWhiteSpace(menuItem.MenuPosition) || string.IsNullOrEmpty(menuItem.MenuText)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
menuItem.Menu = mainMenu.ContentItem;
|
menuItem.Menu = mainMenu.ContentItem;
|
||||||
|
|||||||
Reference in New Issue
Block a user