WP_Site_Health_Auto_Updates::test_wp_automatic_updates_disabled(): array|false

In this article

Checks if automatic updates are disabled.

Return

array|false The test results. False if auto-updates are enabled.

Source

public function test_wp_automatic_updates_disabled() {
	if ( ! class_exists( 'WP_Automatic_Updater' ) ) {
		require_once ABSPATH . 'wp-admin/includes/class-wp-automatic-updater.php';
	}

	$auto_updates = new WP_Automatic_Updater();

	if ( ! $auto_updates->is_disabled() ) {
		return false;
	}

	return array(
		'description' => __( 'All automatic updates are disabled.' ),
		'severity'    => 'fail',
	);
}

Changelog

VersionDescription
5.3.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.