[wp-trac] [WordPress Trac] #40201: Use get_site in clean_blog_cache
WordPress Trac
noreply at wordpress.org
Fri Sep 8 17:45:26 UTC 2017
#40201: Use get_site in clean_blog_cache
-------------------------------------------------+-------------------------
Reporter: spacedmonkey | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 4.9
Component: Networks and Sites | Version:
Severity: normal | Resolution:
Keywords: has-patch dev-feedback needs-unit- | Focuses: multisite
tests |
-------------------------------------------------+-------------------------
Changes (by flixos90):
* keywords: has-patch has-unit-tests dev-feedback => has-patch dev-
feedback needs-unit-tests
* milestone: Awaiting Review => 4.9
Comment:
[attachment:40201.diff] builds upon the previous patch with the goal to
become a 1-to-1-replacement for `refresh_blog_details()`. The function
should be able to also deal with an ID for a site that has just been
deleted (like `refresh_blog_details()` handles it). The patch deprecates
`refresh_blog_details()` and its filter of the same name. The filter has
been moved into `clean_blog_cache()` so that it still fires for code that
now calls that function instead of `refresh_blog_details()`.
Note that this is rather experimental: I definitely think we should aim
for `clean_blog_cache()` to become a 1-to-1-replacement. Whether we
deprecate the old function and filter immediately is another question - I
just did it in this patch, but it can be easily reversed. If the function
is deprecated, we also need to replace all calls to it in core with
`clean_blog_cache()`.
Putting this into 4.9 to give it some more thought. It aligns well with
approaches like #40364 and #40180 / #40228. Also adding back the `needs-
unit-tests` keyword, since you probably forgot to upload the tests
previously @spacedmonkey :)
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40201#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list