WC_Helper_Updater::get_updates_count_based_on_site_status
Get the update count to based on the status of the site.
Метод класса: WC_Helper_Updater{}
Хуков нет.
Возвращает
int.
Использование
$result = WC_Helper_Updater::get_updates_count_based_on_site_status();
Код WC_Helper_Updater::get_updates_count_based_on_site_status() WC Helper Updater::get updates count based on site status WC 10.3.6
public static function get_updates_count_based_on_site_status() {
if ( ! WC_Helper::is_site_connected() ) {
return 0;
}
$count = self::get_updates_count() ?? 0;
if ( ! WC_Woo_Update_Manager_Plugin::is_plugin_installed() || ! WC_Woo_Update_Manager_Plugin::is_plugin_active() ) {
++$count;
}
return $count;
}