Multisite: Move call of `get_blog_details()` inside `ms_site_check()`.

This allows the `ms_site_check` filter or `is_super_admin()` check to return `true` before `get_blog_details()` is used.

Props danielbachhuber.
Fixes #37118.


git-svn-id: https://develop.svn.wordpress.org/trunk@37850 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jeremy Felt 2016-06-22 21:33:20 +00:00
parent 6b35519559
commit 5640b2b02c
1 changed files with 2 additions and 1 deletions

View File

@ -68,7 +68,6 @@ function wp_get_active_network_plugins() {
* @return true|string Returns true on success, or drop-in file to include.
*/
function ms_site_check() {
$blog = get_blog_details();
/**
* Filters checking the status of the current blog.
@ -85,6 +84,8 @@ function ms_site_check() {
if ( is_super_admin() )
return true;
$blog = get_blog_details();
if ( '1' == $blog->deleted ) {
if ( file_exists( WP_CONTENT_DIR . '/blog-deleted.php' ) )
return WP_CONTENT_DIR . '/blog-deleted.php';