[wp-trac] [WordPress Trac] #62035: SITE_ID_CURRENT_SITE broken in 6.3 or later

WordPress Trac noreply at wordpress.org
Thu Sep 12 20:00:55 UTC 2024


#62035: SITE_ID_CURRENT_SITE broken in 6.3 or later
--------------------------------+------------------------------
 Reporter:  scottculverhouse    |       Owner:  (none)
     Type:  defect (bug)        |      Status:  new
 Priority:  normal              |   Milestone:  Awaiting Review
Component:  Networks and Sites  |     Version:  6.3
 Severity:  normal              |  Resolution:
 Keywords:  reporter-feedback   |     Focuses:  multisite
--------------------------------+------------------------------

Comment (by SergeyBiryukov):

 Replying to [comment:4 spacedmonkey]:
 > Mind taking a look @SergeyBiryukov ?

 Thanks for the ping! I saw the ticket, but I can't figure out how to
 reproduce this yet. `$this->id` should only ever be an `int`as noted in
 comment:1::
 > [https://github.com/WordPress/wordpress-
 develop/blob/a8d12183f23694718756c9e84338e12342b2fcb9/src/wp-includes
 /class-wp-network.php#L31-L33 Since version 4.6], the network ID has been
 an `int`, and enforced as such by the [https://github.com/WordPress
 /wordpress-develop/blob/a8d12183f23694718756c9e84338e12342b2fcb9/src/wp-
 includes/class-wp-network.php#L153-L154
 getter]/[https://github.com/WordPress/wordpress-
 develop/blob/a8d12183f23694718756c9e84338e12342b2fcb9/src/wp-includes
 /class-wp-network.php#L197-L199 setter]. In the updated code, `$this->id`
 shouldn't be a string ([https://github.com/WordPress/wordpress-
 develop/blob/a8d12183f23694718756c9e84338e12342b2fcb9/src/wp-includes
 /class-wp-network.php#L65 compared with] `$this->blog_id` which is still a
 string for backward compat).

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


More information about the wp-trac mailing list