Changeset 23794
- Timestamp:
- 03/25/2013 09:29:58 AM (13 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 3 edited
-
general-template.php (modified) (1 diff)
-
ms-blogs.php (modified) (1 diff)
-
ms-functions.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/general-template.php
r23709 r23794 1704 1704 */ 1705 1705 function noindex() { 1706 $public = get_option( 'blog_public' ); 1707 1708 if ( is_multisite() ) { 1709 // Compare local and global and override with the local setting if they 1710 // don't match. 1711 1712 global $current_blog; 1713 1714 if ( ( '' != $public ) && ( $public != $current_blog->public ) ) { 1715 update_blog_status( get_current_blog_id(), 'public', $public ); 1716 $current_blog->public = $public; 1717 } 1718 } 1719 1706 1720 // If the blog is not public, tell robots to go away. 1707 if ( '0' == get_option('blog_public'))1721 if ( '0' == $public ) 1708 1722 wp_no_robots(); 1709 1723 } -
trunk/wp-includes/ms-blogs.php
r23752 r23794 696 696 elseif ( 'deleted' == $pref ) 697 697 ( $value == 1 ) ? do_action( 'make_delete_blog', $blog_id ) : do_action( 'make_undelete_blog', $blog_id ); 698 elseif ( 'public' == $pref ) 699 do_action( 'update_blog_public', $blog_id, $value ); // Moved here from update_blog_public(). 698 700 699 701 return $value; -
trunk/wp-includes/ms-functions.php
r23664 r23794 1735 1735 */ 1736 1736 function update_blog_public( $old_value, $value ) { 1737 global $wpdb; 1738 do_action('update_blog_public'); 1739 update_blog_status( $wpdb->blogid, 'public', (int) $value ); 1737 update_blog_status( get_current_blog_id(), 'public', (int) $value ); 1740 1738 } 1741 1739 add_action('update_option_blog_public', 'update_blog_public', 10, 2);
Note: See TracChangeset
for help on using the changeset viewer.