In insert_blog(), make sure we retrieve the insertion ID from wpdb before calling a function that could invoke queries. props feedmeastraycat. fixes #23400.

git-svn-id: https://develop.svn.wordpress.org/trunk@23511 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2013-02-28 16:53:48 +00:00
parent 11ab449a89
commit 5114e85747
1 changed files with 3 additions and 2 deletions

View File

@ -1104,8 +1104,9 @@ function insert_blog($domain, $path, $site_id) {
if ( ! $result )
return false;
refresh_blog_details($wpdb->insert_id);
return $wpdb->insert_id;
$blog_id = $wpdb->insert_id;
refresh_blog_details( $blog_id );
return $blog_id;
}
/**