WP_Site_Health_Auto_Updates::test_filters_automatic_updater_disabled
Checks if automatic updates are disabled by a filter.
Метод класса: WP_Site_Health_Auto_Updates{}
Хуки из метода
Возвращает
Массив|null. The test results if the automatic_updater_disabled filter is set, or null if the test passed.
Использование
$WP_Site_Health_Auto_Updates = new WP_Site_Health_Auto_Updates(); $WP_Site_Health_Auto_Updates->test_filters_automatic_updater_disabled();
Список изменений
| С версии 5.2.0 | Введена. |
Код WP_Site_Health_Auto_Updates::test_filters_automatic_updater_disabled() WP Site Health Auto Updates::test filters automatic updater disabled WP 7.0.3
public function test_filters_automatic_updater_disabled() {
/** This filter is documented in wp-admin/includes/class-wp-automatic-updater.php */
if ( apply_filters( 'automatic_updater_disabled', false ) ) {
return array(
'description' => sprintf(
/* translators: %s: Name of the filter used. */
__( 'The %s filter is enabled.' ),
'<code>automatic_updater_disabled</code>'
),
'severity' => 'fail',
);
}
return null;
}