always disable venmo funding method

This commit is contained in:
David Remer 2020-07-23 11:12:55 +03:00
parent 6705d2cb26
commit e67a94f931
2 changed files with 2 additions and 4 deletions

View file

@ -322,9 +322,8 @@ class SmartButton implements SmartButtonInterface
}
$disableFunding = $this->settings->has('disable_funding') ?
$this->settings->get('disable_funding') : [];
if (is_array($disableFunding) && count($disableFunding)) {
$params['disable-funding'] = implode(',', $disableFunding);
}
$disableFunding[] = 'venmo';
$params['disable-funding'] = implode(',', $disableFunding);
$smartButtonUrl = add_query_arg($params, 'https://www.paypal.com/sdk/js');
return $smartButtonUrl;
}

View file

@ -376,7 +376,6 @@ return [
'options' => [
'card' => _x('Credit or debit cards', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),
'credit' => _x('PayPal Credit', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),
'venmo' => _x('Venmo', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),
'sepa' => _x('SEPA-Lastschrift', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),
'bancontact' => _x('Bancontact', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),
'eps' => _x('eps', 'Name of payment method', 'woocommerce-paypal-commerce-gateway'),