Skip to content

Commit

Permalink
Upgrade/install: Improve logic check when determining installation st…
Browse files Browse the repository at this point in the history
…atus.

Improve handling of ambiguous return values to determine if a blog is installed.

Props zieladam, xknown.
Merges [49377] to trunk.

git-svn-id: https://develop.svn.wordpress.org/trunk@49386 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
desrosj committed Oct 29, 2020
1 parent a6488f3 commit 2ca15d1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/wp-includes/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -1756,7 +1756,8 @@ function is_blog_installed() {
continue;
}

if ( ! $wpdb->get_results( "DESCRIBE $table;" ) ) {
$described_table = $wpdb->get_results( "DESCRIBE $table;" );
if ( is_array( $described_table ) && count( $described_table ) === 0 ) {
continue;
}

Expand Down

0 comments on commit 2ca15d1

Please sign in to comment.