[wpmu-trac] [WordPress MU Trac] #394: wpmu_create_blog() breaks
with multiple use
WordPress MU Trac
wpmu-trac at lists.automattic.com
Mon Jul 30 22:30:01 GMT 2007
#394: wpmu_create_blog() breaks with multiple use
------------------------+---------------------------------------------------
Reporter: Vimm | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone: WPMU 1.0
Component: component1 | Version: 1.0
Severity: normal | Keywords:
------------------------+---------------------------------------------------
When using wpmu_create_blog() in wpmu-functions.php it will only work
once. If called additional times the blog will be added to the wp_blogs
table but its tables will not be created, resulting in an invalid state.
This is caused by $wp_queries being set in-line in upgrade-schema.php
while it must be updated before the second call to wpmu_create_blog().
This is solved by moving the initialization of $wp_queries into a function
and calling it just before the tables are created (diff file attached).
--
Ticket URL: <http://trac.mu.wordpress.org/ticket/394>
WordPress MU Trac <http://mu.wordpress.org/>
WordPress Multiuser
More information about the wpmu-trac
mailing list