Changes between Initial Version and Version 1 of Ticket #61782, comment 7
- Timestamp:
- 07/29/2024 10:31:25 PM (11 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #61782, comment 7
initial v1 1 @SergeyBiryukov This new helper function may be used during the upgrade routines , where [https://github.com/WordPress/wordpress-develop/blob/9ed3553da6a61a38a1d4c5585e5ac3c9d13d351a/src/wp-admin/includes/update-core.php#L1243 wp-includes/version.php will be replaced], and [https://github.com/WordPress/wordpress-develop/blob/9ed3553da6a61a38a1d4c5585e5ac3c9d13d351a/src/wp-admin/includes/update-core.php#L1259 OPcache will beinvalidated]. However, the return value of `wp_get_wp_version()` won't match the actual current version until the next request. This may need some further thought and testing.1 @SergeyBiryukov This new helper function may be used during the upgrade routines (or by plugins with post-upgrade hooks, for example), where [https://github.com/WordPress/wordpress-develop/blob/9ed3553da6a61a38a1d4c5585e5ac3c9d13d351a/src/wp-admin/includes/update-core.php#L1243 wp-includes/version.php will have been replaced], and [https://github.com/WordPress/wordpress-develop/blob/9ed3553da6a61a38a1d4c5585e5ac3c9d13d351a/src/wp-admin/includes/update-core.php#L1259 OPcache will have been invalidated]. However, the return value of `wp_get_wp_version()` won't match the actual current version until the next request. This may need some further thought and testing. 2 2 3 3 A `$force` parameter may have been useful to include here, to force a fresh file load in such circumstances.