From 99a0145ba18375e474bb848a9fb4f92f09c291d4 Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Fri, 5 Apr 2019 11:08:30 +0000 Subject: [PATCH] Site Health: Remove unused `$wp_config_path` variable. Discovered and fixed during WordCamp London 2019 contributor day. Props m_uysl. Fixes #46808. git-svn-id: https://develop.svn.wordpress.org/trunk@45113 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-debug-data.php | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/wp-admin/includes/class-wp-debug-data.php b/src/wp-admin/includes/class-wp-debug-data.php index 5f96ffa41c..850ae9a860 100644 --- a/src/wp-admin/includes/class-wp-debug-data.php +++ b/src/wp-admin/includes/class-wp-debug-data.php @@ -38,15 +38,7 @@ class WP_Debug_Data { $switched_locale = switch_to_locale( $locale ); } - $upload_dir = wp_get_upload_dir(); - - if ( file_exists( ABSPATH . 'wp-config.php' ) ) { - $wp_config_path = ABSPATH . 'wp-config.php'; - // phpcs:ignore Generic.PHP.NoSilencedErrors.Discouraged - } elseif ( @file_exists( dirname( ABSPATH ) . '/wp-config.php' ) && ! @file_exists( dirname( ABSPATH ) . '/wp-settings.php' ) ) { - $wp_config_path = dirname( ABSPATH ) . '/wp-config.php'; - } - + $upload_dir = wp_get_upload_dir(); $core_current_version = get_bloginfo( 'version' ); $core_updates = get_core_updates(); $core_update_needed = '';