[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:23:35 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                  |   Keywords:  has-unit-tests has-patch
  Focuses:  multisite, performance  |
------------------------------------+--------------------------------------
 The function `get_main_site_id` was added in #29684 . This new function
 adds a way to get the main site id of the current network. This works on
 site id of the site with the same domain / path of the network. However,
 before the point of truth main site id was property on $current_site. Some
 domain mapping plugins build the `$current_site` and `$current_blog`
 manually. Build these globally manually means that the
 $current_site->blog_id will be set. Currently `get_main_site_id` ignores
 these values.

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


More information about the wp-trac mailing list