[wp-trac] [WordPress Trac] #14190: switch_to_blog() should affect $current_blog global

WordPress Trac wp-trac at lists.automattic.com
Thu Sep 13 23:26:24 UTC 2012


#14190: switch_to_blog() should affect $current_blog global
--------------------------+-----------------------
 Reporter:  filosofo      |       Owner:  filosofo
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  3.5
Component:  Multisite     |     Version:  3.0
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |
--------------------------+-----------------------
Changes (by wonderboymusic):

 * keywords:  needs-patch => has-patch
 * milestone:  Future Release => 3.5


Comment:

 get_blog_details is cached, it seems natural that $current_blog would be
 updated, but it's not. Hooking into 'switch_blog' to set it is a hack. I
 do so on eMusic and have had zero problems. Feel like this should be the
 default way it works.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/14190#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list