Skip to content

Commit

Permalink
PAYOSWXP-158: Set 'commit' parameter of paypal script to 'false'
Browse files Browse the repository at this point in the history
  • Loading branch information
momocode-de committed Nov 29, 2024
1 parent 80f4001 commit 0e5efea
Showing 1 changed file with 1 addition and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default class PayonePaymentPayPalV2 extends Plugin {
}

_loadScript() {
const queryString = `client-id=${this.options.clientId}&merchant-id=${this.options.merchantId}&currency=${this.options.currency}&intent=authorize&locale=${this.options.locale}&commit=true&vault=false&disable-funding=card,sepa,bancontact${this.options.showPayLaterButton ? '&enable-funding=paylater' : ''}`;
const queryString = `client-id=${this.options.clientId}&merchant-id=${this.options.merchantId}&currency=${this.options.currency}&intent=authorize&locale=${this.options.locale}&commit=true&vault=false&disable-funding=card,sepa,bancontact${this.options.showPayLaterButton ? '&enable-funding=paylater&commit=false' : ''}`;
const scriptTag = document.createElement('script');

scriptTag.onload = () => this._renderButtons();
Expand All @@ -44,23 +44,17 @@ export default class PayonePaymentPayPalV2 extends Plugin {

_renderButtons() {
paypal.Buttons({

style: {
layout: 'vertical',
color: 'gold',
shape: 'rect',
label: 'checkout',
height: 40,
},

createOrder: this._createOrder.bind(this),

onApprove: this._onApprove.bind(this),

onCancel: this._onCancel.bind(this),

onError: this._onError.bind(this),

}).render('#payone-payment-paypal-v2-button-container');
}

Expand Down

0 comments on commit 0e5efea

Please sign in to comment.