Make WordPress Core

Ticket #61408: 61408.diff

File 61408.diff, 530 bytes (added by joedolson, 11 months ago)

Only execute wp_attachment_is_image if there is a value in site logo.

  • src/wp-includes/general-template.php

     
    10241024        }
    10251025
    10261026        $custom_logo_id = get_theme_mod( 'custom_logo' );
    1027         $is_image       = wp_attachment_is_image( $custom_logo_id );
     1027        $is_image       = ( $custom_logo_id ) ? wp_attachment_is_image( $custom_logo_id ) : false;
    10281028
    10291029        if ( $switched_blog ) {
    10301030                restore_current_blog();