mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Cache API: Add helper function wp_cache_set_last_changed.
Add a helper function called `wp_cache_set_last_changed` to set the last changed value for cache groups. This function has a new action called `wp_cache_set_last_changed`, allowing for developers to cache invalidate when last changed value is changed. Props tillkruess, spacedmonkey, peterwilsoncc, mukesh27, johnjamesjacoby. Fixes #57905. git-svn-id: https://develop.svn.wordpress.org/trunk@55702 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -3918,7 +3918,7 @@ function wp_comments_personal_data_eraser( $email_address, $page = 1 ) {
|
||||
* @since 5.0.0
|
||||
*/
|
||||
function wp_cache_set_comments_last_changed() {
|
||||
wp_cache_set( 'last_changed', microtime(), 'comment' );
|
||||
wp_cache_set_last_changed( 'comment' );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user