mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Docs: Clarify a comment about wp_opcache_invalidate() in _copy_dir().
Follow-up to [48160]. See #52628. git-svn-id: https://develop.svn.wordpress.org/trunk@50460 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
9ca0ce7275
commit
f2367e643b
@ -937,7 +937,7 @@ function update_core( $from, $to ) {
|
||||
* Import $wp_version, $required_php_version, and $required_mysql_version from the new version.
|
||||
* DO NOT globalise any variables imported from `version-current.php` in this function.
|
||||
*
|
||||
* BC Note: $wp_filesystem->wp_content_dir() returned unslashed pre-2.8
|
||||
* BC Note: $wp_filesystem->wp_content_dir() returned unslashed pre-2.8.
|
||||
*/
|
||||
$versions_file = trailingslashit( $wp_filesystem->wp_content_dir() ) . 'upgrade/version-current.php';
|
||||
if ( ! $wp_filesystem->copy( $from . $distro . 'wp-includes/version.php', $versions_file ) ) {
|
||||
@ -1373,7 +1373,10 @@ function _copy_dir( $from, $to, $skip_list = array() ) {
|
||||
}
|
||||
}
|
||||
|
||||
// `wp_opcache_invalidate()` only exists in WordPress 5.5, so don't run it when upgrading to 5.5.
|
||||
/*
|
||||
* `wp_opcache_invalidate()` only exists in WordPress 5.5 or later,
|
||||
* so don't run it when upgrading from older versions.
|
||||
*/
|
||||
if ( function_exists( 'wp_opcache_invalidate' ) ) {
|
||||
wp_opcache_invalidate( $to . $filename );
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user