mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-05 08:59:14 +08:00
do not show dcc gateway on gateway edit screen
This commit is contained in:
parent
44c2acb0f6
commit
e7cbd23155
1 changed files with 3 additions and 1 deletions
|
@ -158,12 +158,14 @@ class WcGatewayModule implements ModuleInterface {
|
|||
static function ( $methods ) use ( $container ): array {
|
||||
$methods[] = $container->get( 'wcgateway.paypal-gateway' );
|
||||
$dcc_applies = $container->get( 'api.helpers.dccapplies' );
|
||||
|
||||
$screen = get_current_screen();
|
||||
/**
|
||||
* The DCC Applies object.
|
||||
*
|
||||
* @var DccApplies $dcc_applies
|
||||
*/
|
||||
if ( $dcc_applies->for_country_currency() ) {
|
||||
if ( $screen->id !== 'woocommerce_page_wc-settings' && $dcc_applies->for_country_currency() ) {
|
||||
$methods[] = $container->get( 'wcgateway.credit-card-gateway' );
|
||||
}
|
||||
return (array) $methods;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue