Automattic\WooCommerce\Internal\Admin\WCPayPromotion

WCPaymentGatewayPreInstallWCPayPromotion::is_dismissed()public staticWC 1.0

Check if the promotional gateaway has been dismissed.

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

Хуков нет.

Возвращает

true|false.

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

$result = WCPaymentGatewayPreInstallWCPayPromotion::is_dismissed();

Код WCPaymentGatewayPreInstallWCPayPromotion::is_dismissed() WC 7.1.0

public static function is_dismissed() {
	$settings = get_option( 'woocommerce_' . self::GATEWAY_ID . '_settings', array() );
	return isset( $settings['is_dismissed'] ) && 'yes' === $settings['is_dismissed'];
}