diff --git a/wp-admin/includes/class-theme-upgrader.php b/wp-admin/includes/class-theme-upgrader.php index 466bb29796..4ff5109e63 100644 --- a/wp-admin/includes/class-theme-upgrader.php +++ b/wp-admin/includes/class-theme-upgrader.php @@ -94,16 +94,18 @@ class Theme_Upgrader extends WP_Upgrader { /* translators: %s: Theme error. */ $this->strings['current_theme_has_errors'] = __( 'The current theme has the following error: "%s".' ); - if ( 'update-theme' === $this->skin->overwrite ) { - $this->strings['installing_package'] = __( 'Updating the theme…' ); - $this->strings['process_failed'] = __( 'Theme update failed.' ); - $this->strings['process_success'] = __( 'Theme updated successfully.' ); - } + if ( ! empty( $this->skin->overwrite ) ) { + if ( 'update-theme' === $this->skin->overwrite ) { + $this->strings['installing_package'] = __( 'Updating the theme…' ); + $this->strings['process_failed'] = __( 'Theme update failed.' ); + $this->strings['process_success'] = __( 'Theme updated successfully.' ); + } - if ( 'downgrade-theme' === $this->skin->overwrite ) { - $this->strings['installing_package'] = __( 'Downgrading the theme…' ); - $this->strings['process_failed'] = __( 'Theme downgrade failed.' ); - $this->strings['process_success'] = __( 'Theme downgraded successfully.' ); + if ( 'downgrade-theme' === $this->skin->overwrite ) { + $this->strings['installing_package'] = __( 'Downgrading the theme…' ); + $this->strings['process_failed'] = __( 'Theme downgrade failed.' ); + $this->strings['process_success'] = __( 'Theme downgraded successfully.' ); + } } } diff --git a/wp-includes/version.php b/wp-includes/version.php index 049149ca9b..423cb7f266 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.5-beta2-48492'; +$wp_version = '5.5-beta2-48493'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.