WordPress.org

Make WordPress Core


Ignore:
Timestamp:
07/01/2015 07:07:20 PM (4 years ago)
Author:
SergeyBiryukov
Message:

Customizer: Avoid PHP notices after [32806].

props adamsilverstein, westonruter.
fixes #32781.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-nav-menus.php

    r32895 r33035  
    754754
    755755        $can_partial_refresh = (
    756             $args['echo']
     756            ! empty( $args['echo'] )
    757757            &&
    758             is_string( $args['fallback_cb'] )
     758            ( empty( $args['fallback_cb'] ) || is_string( $args['fallback_cb'] ) )
    759759            &&
    760             is_string( $args['walker'] )
     760            ( empty( $args['walker'] ) || is_string( $args['walker'] ) )
    761761        );
    762762        $args['can_partial_refresh'] = $can_partial_refresh;
    763763
    764764        if ( ! $can_partial_refresh ) {
    765             unset( $args['fallback_cb'] );
    766             unset( $args['walker'] );
     765            $args['fallback_cb'] = '';
     766            $args['walker'] = '';
    767767        }
    768768
Note: See TracChangeset for help on using the changeset viewer.