WC_Helper_Updater::display_connect_notice_for_woo_plugins │ public static │ WC 11.2.0

Runs on after_plugin_row, show a connect message on WooCommerce.com plugin rows that Core renders no update notice for.

Core only renders its update row -- and with it the message appended by add_connect_woocom_plugin_message() -- when an update is pending, so an up-to-date plugin gives an unconnected store no indication that it won't receive updates.

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

Хуков нет.

Возвращает

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

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

$result = WC_Helper_Updater::display_connect_notice_for_woo_plugins( $plugin_file, $plugin_data ): void;
$plugin_file(строка) (обязательный)
Path to the plugin file relative to the plugins directory.
$plugin_data(массив) (обязательный)
An array of plugin metadata.

Список изменений

С версии 11.2.0 Введена.

Код WC_Helper_Updater::display_connect_notice_for_woo_plugins() WC 11.3.0

public static function display_connect_notice_for_woo_plugins( $plugin_file, $plugin_data ): void {
	if ( 0 === self::get_product_id_for_plugin_row_notice( $plugin_file, $plugin_data ) ) {
		return;
	}

	self::print_plugin_row_notice( $plugin_file, 'woo-connect-notice', self::get_connect_notice( self::CAMPAIGN_PLUGIN_ROW ) );
}