[wp-trac] [WordPress Trac] #41197: Improved caching on WP_Site_Query
WordPress Trac
noreply at wordpress.org
Wed Jun 28 22:14:15 UTC 2017
#41197: Improved caching on WP_Site_Query
--------------------------------+-----------------------------
Reporter: spacedmonkey | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Networks and Sites | Version: 4.6
Severity: normal | Keywords:
Focuses: multisite |
--------------------------------+-----------------------------
In WP_Site_Query, queries are cached as a list of site ids. The key cache
is generated using the query args. But even through the values in the
cache are the same, if you query by `'fields' => 'all'` and `'fields' =>
'ids'`, two caches are generated. By unsetting the `'fields'` arg before
generating the cache key, both queries will use the same cache.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/41197>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list