Make WordPress Core

Ticket #32541: 32541.patch

File 32541.patch, 651 bytes (added by Frozzare, 10 years ago)

Fixed call to do_items on a non-object

  • src/wp-includes/functions.wp-styles.php

     
    5555        _wp_scripts_maybe_doing_it_wrong( __FUNCTION__ );
    5656
    5757        global $wp_styles;
    58         if ( ! ( $wp_styles instanceof WP_Styles ) ) {
    59                 if ( ! $handles ) {
    60                         return array(); // No need to instantiate if nothing is there.
    61                 }
     58        if ( ! ( $wp_styles instanceof WP_Styles ) || ! $handles ) {
     59                return array(); // No need to instantiate if nothing is there.
    6260        }
    6361
    6462        return $wp_styles->do_items( $handles );