WordPress at Your Fingertips
function is not described

WP_Site_Health_Auto_Updates::test_wp_automatic_updates_disabled() public WP 5.3.0

Check if automatic updates are disabled.

{} It's a method of the class: WP_Site_Health_Auto_Updates{}

No Hooks.

Return

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

Usage

$WP_Site_Health_Auto_Updates = new WP_Site_Health_Auto_Updates();
$WP_Site_Health_Auto_Updates->test_wp_automatic_updates_disabled();

Changelog

Since 5.3.0 Introduced.

Code of WP_Site_Health_Auto_Updates::test_wp_automatic_updates_disabled() WP 5.8.2

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',
	);
}