Invalidate the 'update_core' Update check transient when $wp_version changes. See #25831

Built from https://develop.svn.wordpress.org/trunk@26188


git-svn-id: http://core.svn.wordpress.org/trunk@26096 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dion Hulse 2013-11-15 02:35:10 +00:00
parent 8d65f7dc7c
commit 20e5b27731
1 changed files with 4 additions and 0 deletions

View File

@ -31,6 +31,10 @@ function wp_version_check( $extra_stats = array() ) {
$current = get_site_transient( 'update_core' );
$translations = wp_get_installed_translations( 'core' );
// Invalidate the transient when $wp_version changes
if ( is_object( $current ) && $wp_version != $current->version_checked )
$current = false;
if ( ! is_object($current) ) {
$current = new stdClass;
$current->updates = array();