Prevent an offset error if the first menu item is a separator.
props phill_brown. fixes #23182 git-svn-id: https://develop.svn.wordpress.org/trunk@24455 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
c69462faa8
commit
eb49ad7e50
@ -156,7 +156,7 @@ function add_menu_classes($menu) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if ( 0 === strpos($top[2], 'separator') ) { // if separator
|
||||
if ( 0 === strpos($top[2], 'separator') && false !== $lastorder ) { // if separator
|
||||
$first = true;
|
||||
$c = $menu[$lastorder][4];
|
||||
$menu[$lastorder][4] = add_cssclass('menu-top-last', $c);
|
||||
|
Loading…
Reference in New Issue
Block a user