From ef97ca7e07b33695314120d5ede045bb743913c6 Mon Sep 17 00:00:00 2001 From: Jake Spurlock Date: Wed, 27 Jan 2021 23:30:06 +0000 Subject: [PATCH] Site Health: Only run the version checks on the main site. The version checks that are setup in wp-includes/update.php do set up the action, but only for the main site. This brings the changes in [50035] to the 5.6 branch. Fixes #52135. Props audrasjb, SergeyBiryukov, maxpertici, aaribaud. git-svn-id: https://develop.svn.wordpress.org/branches/5.6@50036 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-site-health-auto-updates.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-admin/includes/class-wp-site-health-auto-updates.php b/src/wp-admin/includes/class-wp-site-health-auto-updates.php index 3483bfae91..e965aa3849 100644 --- a/src/wp-admin/includes/class-wp-site-health-auto-updates.php +++ b/src/wp-admin/includes/class-wp-site-health-auto-updates.php @@ -90,7 +90,7 @@ class WP_Site_Health_Auto_Updates { * @return array The test results. */ public function test_wp_version_check_attached() { - if ( ! has_filter( 'wp_version_check', 'wp_version_check' ) ) { + if ( ( ! is_multisite() || ( is_main_site() && is_network_admin() ) ) && ! has_filter( 'wp_version_check', 'wp_version_check' ) ) { return array( 'description' => sprintf( /* translators: %s: Name of the filter used. */