mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Code Modernisation: Replace call_user_func_array() in wp-includes/nav-menu-template.php with a dynamic function call.
Props jrf. See #47678. git-svn-id: https://develop.svn.wordpress.org/trunk@46134 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
db2bc9a167
commit
45827d6e7a
@ -579,9 +579,8 @@ function _wp_menu_item_classes_by_context( &$menu_items ) {
|
||||
*/
|
||||
function walk_nav_menu_tree( $items, $depth, $r ) {
|
||||
$walker = ( empty( $r->walker ) ) ? new Walker_Nav_Menu : $r->walker;
|
||||
$args = array( $items, $depth, $r );
|
||||
|
||||
return call_user_func_array( array( $walker, 'walk' ), $args );
|
||||
return $walker->walk( $items, $depth, $r );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
Reference in New Issue
Block a user