mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-05 08:59:14 +08:00
Do not include credit card section if it does not apply for country currency
This commit is contained in:
parent
cccc879f61
commit
a01c209ad6
1 changed files with 3 additions and 1 deletions
|
@ -245,7 +245,9 @@ return array(
|
|||
|
||||
$dcc_product_status = $container->get( 'wcgateway.helper.dcc-product-status' );
|
||||
assert( $dcc_product_status instanceof DCCProductStatus );
|
||||
if ( ! $dcc_product_status->dcc_is_active() ) {
|
||||
$dcc_applies = $container->get( 'api.helpers.dccapplies' );
|
||||
assert( $dcc_applies instanceof DccApplies );
|
||||
if ( ! $dcc_product_status->dcc_is_active() || ! $dcc_applies->for_country_currency() ) {
|
||||
unset( $sections['ppcp-credit-card-gateway'] );
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue