Upgrade/Install: Correct operator precedence for an error code in `WP_Ajax_Upgrader_Skin::error()`.

Props jrf.
Fixes #47441.
Built from https://develop.svn.wordpress.org/trunk@45487


git-svn-id: http://core.svn.wordpress.org/trunk@45298 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2019-05-31 14:14:52 +00:00
parent 410eb3501b
commit 13da094c39
2 changed files with 3 additions and 3 deletions

View File

@ -95,9 +95,9 @@ class WP_Ajax_Upgrader_Skin extends Automatic_Upgrader_Skin {
}
}
// Count existing errors to generate an unique error code.
// Count existing errors to generate a unique error code.
$errors_count = count( $this->errors->get_error_codes() );
$this->errors->add( 'unknown_upgrade_error_' . $errors_count + 1, $string );
$this->errors->add( 'unknown_upgrade_error_' . ( $errors_count + 1 ), $string );
} elseif ( is_wp_error( $errors ) ) {
foreach ( $errors->get_error_codes() as $error_code ) {
$this->errors->add( $error_code, $errors->get_error_message( $error_code ), $errors->get_error_data( $error_code ) );

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.3-alpha-45486';
$wp_version = '5.3-alpha-45487';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.