woocommerce / woocommerce-gateway-paypal-express-checkout

58 stars 65 forks source link

Make the SDK script args filterable #763

Closed mattallan closed 4 years ago

mattallan commented 4 years ago

See #762 for the original PR that was opened and then not long after, closed by the author.

I found this user has opened a ticket on WP.org as well: https://wordpress.org/support/topic/can-i-checkout-through-paypal-instead-of-redirect/

I can understand why people may want to filter the script args so they can change some of the values we set like: locale, currency and commit, or even set any parameters we're not using (see more details on all available script args in the PayPal docs on Customising the PayPal JavaScript SDK Script)

This PR is similar to #762 except I've added a few extra args to the filter to include: $client and $settings.