Ticket #24035: 24035.diff
File 24035.diff, 880 bytes (added by , 11 years ago) |
---|
-
wp-includes/nav-menu-template.php
189 189 && $args->fallback_cb && is_callable( $args->fallback_cb ) ) 190 190 return call_user_func( $args->fallback_cb, (array) $args ); 191 191 192 if ( ! $menu || is_wp_error( $menu ) || empty( $menu_items) )192 if ( ! $menu || is_wp_error( $menu ) ) 193 193 return false; 194 194 195 195 $nav_menu = $items = ''; … … 239 239 $items = apply_filters( 'wp_nav_menu_items', $items, $args ); 240 240 $items = apply_filters( "wp_nav_menu_{$menu->slug}_items", $items, $args ); 241 241 242 // Bail if there are no items 243 if ( empty( $items ) ) 244 return false; 245 242 246 $nav_menu .= sprintf( $args->items_wrap, esc_attr( $wrap_id ), esc_attr( $wrap_class ), $items ); 243 247 unset( $items ); 244 248