[wp-trac] [WordPress Trac] #41936: get_main_site_id ignores custom values of $current_site->blog_id

WordPress Trac noreply at wordpress.org
Wed Sep 20 22:31:00 UTC 2017


#41936: get_main_site_id ignores custom values of $current_site->blog_id
--------------------------------------+------------------------------------
 Reporter:  spacedmonkey              |       Owner:
     Type:  defect (bug)              |      Status:  new
 Priority:  normal                    |   Milestone:  Awaiting Review
Component:  Networks and Sites        |     Version:  trunk
 Severity:  normal                    |  Resolution:
 Keywords:  has-unit-tests has-patch  |     Focuses:  multisite,
                                      |  performance
--------------------------------------+------------------------------------

Comment (by spacedmonkey):

 [https://core.trac.wordpress.org/attachment/ticket/41936/41936-test.diff
 41936-test.diff]
 This is a test if blog_id is set from another source, such as a sunrise
 file. Test is currently failing.

 [https://core.trac.wordpress.org/attachment/ticket/41936/41936.diff
 41936.diff]
 This is my solution, the moves the logic of getting blog_id into the
 WP_Network. It also makes the get_main_site_id method public, so it can be
 called in the bootstrap process.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/41936#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list