Menus: Fix `_wp_expand_nav_menu_post_data()` for PHP 5.2.
[37748] introduced `_wp_expand_nav_menu_post_data()` together with an `array_replace_recursive()` compatibility function for PHP 5.2. Even though that compat function is tried and tested in other projects like BuddyPress, we need to add additional `isset()` checks in order to avoid 'Undefined index' notices in our case. See #36590. Built from https://develop.svn.wordpress.org/trunk@37750 git-svn-id: http://core.svn.wordpress.org/trunk@37715 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ca25c94613
commit
ddca3c1e01
|
@ -471,7 +471,10 @@ if ( ! function_exists( 'array_replace_recursive' ) ) :
|
|||
unset( $bref_stack[ key( $bref_stack ) ] );
|
||||
|
||||
foreach ( array_keys( $head ) as $key ) {
|
||||
if ( isset( $key, $bref ) && is_array( $bref[ $key ] ) && is_array( $head[ $key ] ) ) {
|
||||
if ( isset( $key, $bref ) &&
|
||||
isset( $bref[ $key ] ) && is_array( $bref[ $key ] ) &&
|
||||
isset( $head[ $key ] ) && is_array( $head[ $key ] )
|
||||
) {
|
||||
$bref_stack[] = &$bref[ $key ];
|
||||
$head_stack[] = $head[ $key ];
|
||||
} else {
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.6-alpha-37749';
|
||||
$wp_version = '4.6-alpha-37750';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue