From 2093f293c7a185a6a92be2e563acb3f7b095bc2b Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Fri, 5 Jul 2013 15:17:31 +0000 Subject: [PATCH] Don't sync the blog public option from noindex(). This can cause race conditions. fixes #23155 git-svn-id: https://develop.svn.wordpress.org/trunk@24559 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/general-template.php | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php index ddc45e2fd7..7d7a4a90d9 100644 --- a/wp-includes/general-template.php +++ b/wp-includes/general-template.php @@ -1734,22 +1734,8 @@ function wlwmanifest_link() { * @since 2.1.0 */ function noindex() { - $public = get_option( 'blog_public' ); - - if ( is_multisite() ) { - // Compare local and global and override with the local setting if they - // don't match. - - global $current_blog; - - if ( ( '' != $public ) && ( $public != $current_blog->public ) ) { - update_blog_status( get_current_blog_id(), 'public', $public ); - $current_blog->public = $public; - } - } - // If the blog is not public, tell robots to go away. - if ( '0' == $public ) + if ( '0' == get_option('blog_public') ) wp_no_robots(); }