Make WordPress Core


Ignore:
Timestamp:
03/10/2016 06:56:56 PM (9 years ago)
Author:
obenland
Message:

Tests: Introduce multisite unit tests.

Makes sure custom logo functions work for other sites within a network.
Fixes a bug in get_custom_logo() where the correct logo was returned, but
linked to the wrong site.

H/t ocean90.
See #33755, #36086.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/general-template.php

    r36939 r36949  
    877877
    878878    $custom_logo_id = get_theme_mod( 'custom_logo' );
    879 
    880     if ( is_multisite() && ms_is_switched() ) {
    881         restore_current_blog();
    882     }
    883     $size = get_theme_support( 'custom-logo', 'size' );
     879    $size           = get_theme_support( 'custom-logo', 'size' );
    884880
    885881    // We have a logo. Logo is go.
     
    901897            esc_attr( $size )
    902898        );
     899    }
     900
     901    if ( is_multisite() && ms_is_switched() ) {
     902        restore_current_blog();
    903903    }
    904904
Note: See TracChangeset for help on using the changeset viewer.