Ticket #17376: 17376.5.diff
File 17376.5.diff, 1.0 KB (added by , 9 years ago) |
---|
-
src/wp-includes/ms-settings.php
119 119 $current_blog->blog_id = $blog_id = 1; 120 120 } 121 121 122 // Admin access must have an exact path match. 123 if ( ! empty( $current_blog ) && is_admin() && 0 !== strcasecmp( $current_blog->path, $path ) ) { 124 $scheme = is_ssl() ? 'https' : 'http'; 125 header( "Location: $scheme://{$current_blog->domain}{$current_blog->path}" ); 126 exit; 127 } 128 122 129 // No site has been found, bail. 123 130 if ( empty( $current_blog ) ) { 124 131 // We're going to redirect to the network URL, with some possible modifications. … … 149 156 if ( '%siteurl%' !== NOBLOGREDIRECT ) { 150 157 $destination = NOBLOGREDIRECT; 151 158 } 159 } elseif ( is_admin() ) { 160 $destination .= 'wp-admin/'; 152 161 } elseif ( 0 === strcasecmp( $current_site->domain, $domain ) ) { 153 162 /* 154 163 * If the domain we were searching for matches the network's domain,