﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
12648	Wpmu_create_blog fails if it is called multiple times	jpotkanski		"

Test:
ids[] = wpmu_create_blog($current_site->domain, '/test1/', 'Test Blog 1', 1, array( ""public"" => 0 ), $current_site->id);
ids[] = wpmu_create_blog($current_site->domain, '/test2/', 'Test Blog 2', 1, array( ""public"" => 0 ), $current_site->id);
ids[] = wpmu_create_blog($current_site->domain, '/test3/', 'Test Blog 3', 1, array( ""public"" => 0 ), $current_site->id);

Test Blog 1 will create fine. 

Test Blog 2 and 3 will be properly created in wp_blogs but will not have their local specific tables created. 

The bug is in the design of require_once upgrade.php in the install_blog function. Deep underneath this sets a global $wp_queries. Long term, the global $wp_queries NEEDS to be deprecated in favor of a function.

The patch will regex replace the correct blog id if $wp_queries exists."	defect (bug)	closed	normal		Multisite	2.9.2	normal	duplicate		
