Ticket #13787: 13787.diff
File 13787.diff, 920 bytes (added by , 15 years ago) |
---|
-
wp-includes/nav-menu-template.php
162 162 if ( $menu && ! is_wp_error($menu) && !isset($menu_items) ) 163 163 $menu_items = wp_get_nav_menu_items( $menu->term_id ); 164 164 165 // If no menu was found or if the menu has no items , call the fallback_cb if it exists166 if ( ( !$menu || is_wp_error($menu) || ( isset($menu_items) && empty($menu_items) ) )165 // If no menu was found or if the menu has no items and no location was requested, call the fallback_cb if it exists 166 if ( ( !$menu || is_wp_error($menu) || ( isset($menu_items) && empty($menu_items) && !$args->theme_location ) ) 167 167 && ( function_exists($args->fallback_cb) || is_callable( $args->fallback_cb ) ) ) 168 168 return call_user_func( $args->fallback_cb, (array) $args ); 169 169