mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-29 15:47:38 +02:00
Avoid confusion by clarifying an inline comment on logic for performing multisite upgrades.
Props dmchale for the initial patch. Fixes #30837. Built from https://develop.svn.wordpress.org/trunk@31297 git-svn-id: http://core.svn.wordpress.org/trunk@31278 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
9a17233ca1
commit
de1f0a0487
@ -63,7 +63,11 @@ if ( get_option('db_upgraded') ) {
|
|||||||
*/
|
*/
|
||||||
} elseif ( apply_filters( 'do_mu_upgrade', true ) ) {
|
} elseif ( apply_filters( 'do_mu_upgrade', true ) ) {
|
||||||
$c = get_blog_count();
|
$c = get_blog_count();
|
||||||
// If 50 or fewer sites, run every time. Else, run "about ten percent" of the time. Shh, don't check that math.
|
|
||||||
|
/*
|
||||||
|
* If there are 50 or fewer sites, run every time. Otherwise, throttle to reduce load:
|
||||||
|
* attempt to do no more than threshold value, with some +/- allowed.
|
||||||
|
*/
|
||||||
if ( $c <= 50 || ( $c > 50 && mt_rand( 0, (int)( $c / 50 ) ) == 1 ) ) {
|
if ( $c <= 50 || ( $c > 50 && mt_rand( 0, (int)( $c / 50 ) ) == 1 ) ) {
|
||||||
require_once( ABSPATH . WPINC . '/http.php' );
|
require_once( ABSPATH . WPINC . '/http.php' );
|
||||||
$response = wp_remote_get( admin_url( 'upgrade.php?step=1' ), array( 'timeout' => 120, 'httpversion' => '1.1' ) );
|
$response = wp_remote_get( admin_url( 'upgrade.php?step=1' ), array( 'timeout' => 120, 'httpversion' => '1.1' ) );
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.2-alpha-31296';
|
$wp_version = '4.2-alpha-31297';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user