Make WordPress Core

Ticket #17196: 17196.diff

File 17196.diff, 1.5 KB (added by ryan, 13 years ago)
  • wp-admin/network/admin.php

     
    1515if ( ! is_multisite() )
    1616        wp_die( __( 'Multisite support is not enabled.' ) );
    1717
    18 if ( ( $current_blog->domain != $current_site->domain ) || ( $current_blog->path != $current_site->path ) ) {
     18$redirect_network_admin_request = ( ( $current_blog->domain != $current_site->domain ) || ( $current_blog->path != $current_site->path ) );
     19$redirect_network_admin_request = apply_filters( 'redirect_network_admin_request', $redirect_network_admin_request );
     20if ( $redirect_network_admin_request ) {
    1921        wp_redirect( network_admin_url() );
    2022        exit;
    2123}
     24unset( $redirect_network_admin_request );
    2225?>
  • wp-admin/user/admin.php

     
    1616        exit;
    1717}
    1818
    19 if ( ( $current_blog->domain != $current_site->domain ) || ( $current_blog->path != $current_site->path ) ) {
     19$redirect_user_admin_request = ( ( $current_blog->domain != $current_site->domain ) || ( $current_blog->path != $current_site->path ) );
     20$redirect_user_admin_request = apply_filters( 'redirect_user_admin_request', $redirect_user_admin_request );
     21if ( $redirect_user_admin_request ) {
    2022        wp_redirect( user_admin_url() );
    2123        exit;
    2224}
     25unset( $redirect_user_admin_request );
     26
    2327?>