#35251 closed defect (bug) (fixed)
'networks' should be global cache group
| Reported by: | johnjamesjacoby | Owned by: | dd32 |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.4.2 |
| Component: | Networks and Sites | Version: | 4.4 |
| Severity: | normal | Keywords: | needs-patch good-first-bug |
| Cc: | Focuses: | multisite |
Description (last modified by )
The networks cache group is currently being prefixed with a blog ID, making it a repeated cache miss and duplicating cached data when using multiple networks and querying for them between dashboards.
The backstory goes that WordPress 4.4 introduced the WP_Network class (see: #31985) and with it came a simple new method for getting a network, aptly titled get_instance(). This method is used in ms-settings.php and ms-load.php in place of some previously duplicated and uncached code, and is used to retrieve a network's details from the wp_sites database table. That query is wrapped in a new cache check with a new networks cache group, but this group was never added to the global cache groups array.
It's not a regression, but it could be slipped into 4.4.1 as it was an unintentional oversight that could cause cache corruption in multi-network setups.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
This is a shame this didn't get into 4.4.1. This there any chance of getting it in the latest release?