Index: src/wp-includes/ms-blogs.php
===================================================================
--- src/wp-includes/ms-blogs.php	(revision 25706)
+++ src/wp-includes/ms-blogs.php	(working copy)
@@ -17,7 +17,13 @@
 	global $wpdb;
 
 	update_blog_details( $wpdb->blogid, array('last_updated' => current_time('mysql', true)) );
-
+	/**
+	 * Fires after the blog details are updated.
+	 *
+	 * @since MU
+	 *
+	 * @param integer $wpdb->blogid The ID of the blog.
+	 */
 	do_action( 'wpmu_blog_updated', $wpdb->blogid );
 }
 
@@ -26,7 +32,7 @@
  *
  * @since MU
  *
- * @param int $blog_id Blog ID
+ * @param integer $blog_id The ID of the blog.
  * @return string
  */
 function get_blogaddress_by_id( $blog_id ) {
@@ -206,6 +212,13 @@
 	$details->post_count	= get_option( 'post_count' );
 	restore_current_blog();
 
+	/**
+	 * Filter the blog's details.
+	 *
+	 * @since MU
+	 *
+	 * @param object $detail The details of the blog.
+	 */
 	$details = apply_filters( 'blog_details', $details );
 
 	wp_cache_set( $blog_id . $all, $details, 'blog-details' );
@@ -239,6 +252,13 @@
 
 	clean_blog_cache( $details );
 
+	/**
+	 * Fires after the blog details cache is cleared.
+	 *
+	 * @since MU
+	 *
+	 * @param integer $blog_id The ID of the blog.
+	 */
 	do_action( 'refresh_blog_details', $blog_id );
 }
 
@@ -281,34 +301,94 @@
 
 	// If spam status changed, issue actions.
 	if ( $details[ 'spam' ] != $current_details[ 'spam' ] ) {
-		if ( $details[ 'spam' ] == 1 )
+		if ( $details[ 'spam' ] == 1 ) {
+			/**
+			 * Fires when the blog status is changed to spam.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'make_spam_blog', $blog_id );
-		else
+		} else {
+			/**
+			 * Fires when the blog status is changed to ham.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'make_ham_blog', $blog_id );
+		}
 	}
 
 	// If mature status changed, issue actions.
 	if ( $details[ 'mature' ] != $current_details[ 'mature' ] ) {
-		if ( $details[ 'mature' ] == 1 )
+		if ( $details[ 'mature' ] == 1 ) {
+			/**
+			 * Fires when the blog status is changed to mature.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'mature_blog', $blog_id );
-		else
+		} else {
+			/**
+			 * Fires when the blog status is changed to unmature.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'unmature_blog', $blog_id );
+		}
 	}
 
 	// If archived status changed, issue actions.
 	if ( $details[ 'archived' ] != $current_details[ 'archived' ] ) {
-		if ( $details[ 'archived' ] == 1 )
+		if ( $details[ 'archived' ] == 1 ) {
+			/**
+			 * Fires when the blog status is changed to archived.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'archive_blog', $blog_id );
-		else
+		} else {
+			/**
+			 * Fires when the blog status is changed to unarchived.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'unarchive_blog', $blog_id );
+		}
 	}
 
 	// If deleted status changed, issue actions.
 	if ( $details[ 'deleted' ] != $current_details[ 'deleted' ] ) {
-		if ( $details[ 'deleted' ] == 1 )
+		if ( $details[ 'deleted' ] == 1 ) {
+			/**
+			 * Fires when the blog status is changed to deleted.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'make_delete_blog', $blog_id );
-		else
+		} else {
+			/**
+			 * Fires when the blog status is changed to undeleted.
+			 *
+			 * @since MU
+			 *
+			 * @param integer $blog_id The ID of the blog.
+			 */
 			do_action( 'make_undelete_blog', $blog_id );
+		}
 	}
 
 	if ( isset( $details[ 'public' ] ) ) {
@@ -372,6 +452,14 @@
 	$value = get_option( $option, $default );
 	restore_current_blog();
 
+	/**
+	 * Filter the option of blog depending on the $option.
+	 *
+	 * @since MU
+	 *
+	 * @param string  $value The value of option.
+	 * @param integer $id    Blog ID
+	 */
 	return apply_filters( 'blog_option_' . $option, $value, $id );
 }
 
@@ -492,6 +580,14 @@
 	* set the right vars, do the associated actions, but skip
 	* the extra unnecessary work */
 	if ( $new_blog == $GLOBALS['blog_id'] ) {
+		/**
+		 * Fires when the blog is switched..
+		 *
+		 * @since MU
+		 *
+		 * @param integer $new_blog The ID of the new blog.
+		 * @param integer $new_blog The ID of the new blog.
+		 */
 		do_action( 'switch_blog', $new_blog, $new_blog );
 		$GLOBALS['switched'] = true;
 		return true;
@@ -529,6 +625,7 @@
 		$current_user->for_blog( $new_blog );
 	}
 
+	//duplicate_hook
 	do_action( 'switch_blog', $new_blog, $prev_blog_id );
 	$GLOBALS['switched'] = true;
 
@@ -552,6 +649,7 @@
 	$blog = array_pop( $GLOBALS['_wp_switched_stack'] );
 
 	if ( $GLOBALS['blog_id'] == $blog ) {
+		//duplicate_hook
 		do_action( 'switch_blog', $blog, $blog );
 		// If we still have items in the switched stack, consider ourselves still 'switched'
 		$GLOBALS['switched'] = ! empty( $GLOBALS['_wp_switched_stack'] );
@@ -590,6 +688,7 @@
 		$current_user->for_blog( $blog );
 	}
 
+	//duplicate_hook
 	do_action( 'switch_blog', $blog, $prev_blog_id );
 
 	// If we still have items in the switched stack, consider ourselves still 'switched'
@@ -661,16 +760,49 @@
 
 	refresh_blog_details( $blog_id );
 
-	if ( 'spam' == $pref )
-		( $value == 1 ) ? do_action( 'make_spam_blog', $blog_id ) :	do_action( 'make_ham_blog', $blog_id );
-	elseif ( 'mature' == $pref )
-		( $value == 1 ) ? do_action( 'mature_blog', $blog_id ) : do_action( 'unmature_blog', $blog_id );
-	elseif ( 'archived' == $pref )
-		( $value == 1 ) ? do_action( 'archive_blog', $blog_id ) : do_action( 'unarchive_blog', $blog_id );
-	elseif ( 'deleted' == $pref )
-		( $value == 1 ) ? do_action( 'make_delete_blog', $blog_id ) : do_action( 'make_undelete_blog', $blog_id );
-	elseif ( 'public' == $pref )
+	if ( 'spam' == $pref ) {
+		if ( $value == 1 ) {
+			//duplicate_hook
+			do_action( 'make_spam_blog', $blog_id );
+		} else {
+			//duplicate_hook
+			do_action( 'make_ham_blog', $blog_id );
+		}
+	} elseif ( 'mature' == $pref ) {
+		if ( $value == 1 ) {
+			//duplicate_hook
+			do_action( 'mature_blog', $blog_id );
+		} else {
+			//duplicate_hook
+			do_action( 'unmature_blog', $blog_id );
+		}
+	} elseif ( 'archived' == $pref ) {
+		if ( $value == 1 ) {
+			//duplicate_hook
+			do_action( 'archive_blog', $blog_id );
+		} else {
+			//duplicate_hook
+			do_action( 'unarchive_blog', $blog_id );
+		}
+	} elseif ( 'deleted' == $pref ) {
+		if ( $value == 1 ) {
+			//duplicate_hook
+			do_action( 'make_delete_blog', $blog_id );
+		} else {
+			//duplicate_hook
+			do_action( 'make_undelete_blog', $blog_id );
+		}
+	} elseif ( 'public' == $pref ) {
+		/**
+		 * Fires after the current blog's 'public' setting is changed.
+		 *
+		 * @since MU
+		 *
+		 * @param integer $blog_id BLog ID
+		 * @param string  $value   The value of blog status.
+ 		 */
 		do_action( 'update_blog_public', $blog_id, $value ); // Moved here from update_blog_public().
+	}
 
 	return $value;
 }
