WC_Helper_Updater::add_hook_for_modifying_update_notices │ public static │ WC 1.0

Add the hook for modifying default WPCore update notices on the plugins management page.

Метод класса: WC_Helper_Updater{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$result = WC_Helper_Updater::add_hook_for_modifying_update_notices();

Код WC_Helper_Updater::add_hook_for_modifying_update_notices() WC 11.2.1

public static function add_hook_for_modifying_update_notices() {
	if ( ! WC_Woo_Update_Manager_Plugin::is_plugin_active() || ! WC_Helper::is_site_connected() ) {
		add_action( 'load-plugins.php', array( __CLASS__, 'setup_update_plugins_messages' ), 11 );
	}
	if ( WC_Helper::is_site_connected() ) {
		add_action( 'load-plugins.php', array( __CLASS__, 'setup_message_for_expired_and_expiring_subscriptions' ), 11 );
		add_action( 'load-plugins.php', array( __CLASS__, 'setup_message_for_plugins_without_subscription' ), 11 );
		add_action( 'after_plugin_row', array( __CLASS__, 'display_subscription_notice_for_woo_plugins' ), 10, 2 );
	} else {
		add_action( 'after_plugin_row', array( __CLASS__, 'display_connect_notice_for_woo_plugins' ), 10, 2 );
	}
}