Prevent update API requests on every load of themes.php when no updates are available. Fixes #16362

git-svn-id: http://svn.automattic.com/wordpress/trunk@17618 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
dd32 2011-04-07 09:56:20 +00:00
parent efa709d1b5
commit 197e081e19
1 changed files with 3 additions and 3 deletions

View File

@ -280,11 +280,11 @@ function wp_update_themes( ) {
$new_update = new stdClass;
$new_update->last_checked = time( );
$new_update->checked = $checked;
$response = unserialize( $raw_response['body'] );
if ( $response ) {
$new_update->checked = $checked;
if ( false !== $response )
$new_update->response = $response;
}
set_site_transient( 'update_themes', $new_update );
}