From da6ab833d534d5c4cf0b815d3dce345cec6569cd Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Thu, 19 Nov 2020 12:05:06 +0000 Subject: [PATCH] Coding Standards: Remove redundant `isset()` check in `core_upgrade_preamble()`. `isset()` can be safely used to check properties and subproperties of objects directly. Follow-up to [49638]. See #51799. Built from https://develop.svn.wordpress.org/trunk@49668 git-svn-id: http://core.svn.wordpress.org/trunk@49391 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/update-core.php | 4 +++- wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-admin/update-core.php b/wp-admin/update-core.php index 47f4b6ae52..3beb87b6ed 100644 --- a/wp-admin/update-core.php +++ b/wp-admin/update-core.php @@ -232,7 +232,7 @@ function core_upgrade_preamble() { $wp_version = get_bloginfo( 'version' ); $updates = get_core_updates(); - if ( isset( $updates[0] ) && isset( $updates[0]->version ) && version_compare( $updates[0]->version, $wp_version, '>' ) ) { + if ( isset( $updates[0]->version ) && version_compare( $updates[0]->version, $wp_version, '>' ) ) { echo '

'; _e( 'An updated version of WordPress is available.' ); echo '

'; @@ -258,6 +258,7 @@ function core_upgrade_preamble() { echo ''; } echo ''; + // Don't show the maintenance mode notice when we are only showing a single re-install option. if ( $updates && ( count( $updates ) > 1 || 'latest' !== $updates[0]->response ) ) { echo '

' . __( 'While your site is being updated, it will be in maintenance mode. As soon as your updates are complete, this mode will be deactivated.' ) . '

'; @@ -270,6 +271,7 @@ function core_upgrade_preamble() { $normalized_version ) . '

'; } + dismissed_updates(); } diff --git a/wp-includes/version.php b/wp-includes/version.php index ca2cb9e9bb..8b9405b107 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.7-alpha-49651'; +$wp_version = '5.7-alpha-49668'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.