Multisite: Add deleted_blog action after site has been deleted.
Props pauldewouters, johnjamesjacoby. Fixes #25584. Built from https://develop.svn.wordpress.org/trunk@40351 git-svn-id: http://core.svn.wordpress.org/trunk@40258 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -173,6 +173,16 @@ function wpmu_delete_blog( $blog_id, $drop = false ) {
|
||||
clean_blog_cache( $blog );
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires after the site is deleted from the network.
|
||||
*
|
||||
* @since 4.8.0
|
||||
*
|
||||
* @param int $blog_id The site ID.
|
||||
* @param bool $drop True if site's tables should be dropped. Default is false.
|
||||
*/
|
||||
do_action( 'deleted_blog', $blog_id, $drop );
|
||||
|
||||
if ( $switch )
|
||||
restore_current_blog();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user