Ticket #18201: 18201-no_partial.patch
File 18201-no_partial.patch, 2.4 KB (added by , 11 years ago) |
---|
-
src/wp-admin/includes/class-wp-upgrader.php
1254 1254 // Pre-cache the checksums for the versions we care about 1255 1255 get_core_checksums( array( $wp_version, $current->version ) ); 1256 1256 1257 $ no_partial = false;1257 $partial = true; 1258 1258 if ( $parsed_args['do_rollback'] ) 1259 $ no_partial = true;1259 $partial = false; 1260 1260 elseif ( $parsed_args['pre_check_md5'] && ! $this->check_files() ) 1261 $ no_partial = true;1261 $partial = false; 1262 1262 1263 1263 // If partial update is returned from the API, use that, unless we're doing a reinstall. 1264 1264 // If we cross the new_bundled version number, then use the new_bundled zip. … … 1266 1266 // If the API returns a no_content zip, go with it. Finally, default to the full zip. 1267 1267 if ( $parsed_args['do_rollback'] && $current->packages->rollback ) 1268 1268 $to_download = 'rollback'; 1269 elseif ( $current->packages->partial && 'reinstall' != $current->response && $wp_version == $current->partial_version && ! $no_partial )1269 elseif ( $current->packages->partial && 'reinstall' != $current->response && $wp_version == $current->partial_version && $partial ) 1270 1270 $to_download = 'partial'; 1271 1271 elseif ( $current->packages->new_bundled && version_compare( $wp_version, $current->new_bundled, '<' ) 1272 1272 && ( ! defined( 'CORE_UPGRADE_SKIP_NEW_BUNDLED' ) || ! CORE_UPGRADE_SKIP_NEW_BUNDLED ) ) … … 1640 1640 $item->language 1641 1641 ); 1642 1642 } 1643 1643 1644 1644 break; 1645 1645 } 1646 1646 … … 1688 1688 return; 1689 1689 1690 1690 // Don't automatically run these thins, as we'll handle it ourselves 1691 remove_action( 'upgrader_process_complete', array( 'Language_Pack_Upgrader', 'async_upgrade' ), 20, 3 ); 1692 remove_action( 'upgrader_process_complete', 'wp_version_check' ); 1693 remove_action( 'upgrader_process_complete', 'wp_update_plugins' ); 1694 remove_action( 'upgrader_process_complete', 'wp_update_themes' ); 1691 remove_action( 'upgrader_process_complete', array( 'Language_Pack_Upgrader', 'async_upgrade' ), 20, 3 ); 1692 remove_action( 'upgrader_process_complete', 'wp_version_check' ); 1693 remove_action( 'upgrader_process_complete', 'wp_update_plugins' ); 1694 remove_action( 'upgrader_process_complete', 'wp_update_themes' ); 1695 1695 1696 1696 // Next, Plugins 1697 1697 wp_update_plugins(); // Check for Plugin updates