mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-04 08:47:23 +08:00
Consider manual renewal and vaulting option when displaying buttons on product page
This commit is contained in:
parent
3163593027
commit
cf68af182c
2 changed files with 22 additions and 5 deletions
|
@ -233,11 +233,15 @@ class SingleProductBootstap {
|
|||
this.form(),
|
||||
this.errorHandler
|
||||
);
|
||||
|
||||
if(!this.gateway.vaultingEnabled){
|
||||
return;
|
||||
}
|
||||
|
||||
if (
|
||||
! this.gateway.vaultingEnabled &&
|
||||
[ 'subscription', 'variable-subscription' ].includes(
|
||||
this.gateway.productType
|
||||
) &&
|
||||
this.gateway.manualRenewalEnabled !== '1'
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (
|
||||
PayPalCommerceGateway.data_client_id.has_subscriptions &&
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue