mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-09 18:08:09 +01:00
In wp_nav_menu()
, ensure that the $menu
arg is populated when passed to filters.
Props greuben, chriscct7. Fixes #16594. Built from https://develop.svn.wordpress.org/trunk@32803 git-svn-id: http://core.svn.wordpress.org/trunk@32774 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
6148f3cd41
commit
0cc29d8bb7
@ -291,6 +291,10 @@ function wp_nav_menu( $args = array() ) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ( empty( $args->menu ) ) {
|
||||||
|
$args->menu = $menu;
|
||||||
|
}
|
||||||
|
|
||||||
// If the menu exists, get its items.
|
// If the menu exists, get its items.
|
||||||
if ( $menu && ! is_wp_error($menu) && !isset($menu_items) )
|
if ( $menu && ! is_wp_error($menu) && !isset($menu_items) )
|
||||||
$menu_items = wp_get_nav_menu_items( $menu->term_id, array( 'update_post_term_cache' => false ) );
|
$menu_items = wp_get_nav_menu_items( $menu->term_id, array( 'update_post_term_cache' => false ) );
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.3-alpha-32802';
|
$wp_version = '4.3-alpha-32803';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user