Invalidate cache for SiteGround Speed Optimizer when coming soon options are changed (#48523)
* chore: Invalidate cache for SiteGround Speed Optimizer and WP Engine The code changes in `ComingSoonCacheInvalidator.php` add cache invalidation for SiteGround Speed Optimizer and WP Engine. This ensures that the cache is cleared when necessary, improving the performance of the website. * Add changelog * Add a slash to ensure calls are made in global namespace * Use sg_cachepress_purge_cache * Update plugins/woocommerce/src/Internal/ComingSoon/ComingSoonCacheInvalidator.php Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com> * Fix lint * Update plugins/woocommerce/changelog/update-purge-cache-siteground-wpengine --------- Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com> Co-authored-by: moon <moon.kyong@automattic.com>
This commit is contained in:
parent
0e1ae1717d
commit
1dd10f6269
|
@ -0,0 +1,4 @@
|
|||
Significance: patch
|
||||
Type: update
|
||||
|
||||
Invalidate cache for SiteGround Speed Optimizer
|
|
@ -39,5 +39,10 @@ class ComingSoonCacheInvalidator {
|
|||
)
|
||||
);
|
||||
}
|
||||
|
||||
// Invalidate the SiteGround Speed Optimizer cache.
|
||||
if ( function_exists( '\sg_cachepress_purge_cache' ) ) {
|
||||
\sg_cachepress_purge_cache();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue