woocommerce_payment_gateway_supports хук-фильтрWC 1.5.7

Check if a gateway supports a given feature.

Gateways should override this to declare support (or lack of support) for a feature. For backward compatibility, gateways support 'products' by default, but nothing else.


add_filter( 'woocommerce_payment_gateway_supports', 'wp_kama_woocommerce_payment_gateway_supports_filter', 10, 2 );

 * Function for `woocommerce_payment_gateway_supports` filter-hook.
 * @param  $feature 
 * @param  $that    
 * @return 
function wp_kama_woocommerce_payment_gateway_supports_filter( $feature, $that ){

	// filter...
	return $feature;

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

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

Где вызывается хук

woocommerce/includes/abstracts/abstract-wc-payment-gateway.php 422
return apply_filters( 'woocommerce_payment_gateway_supports', in_array( $feature, $this->supports ), $feature, $this );

Где используется хук в WooCommerce

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