mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-01 07:02:48 +08:00
Fix available gateways in order-pay page
This commit is contained in:
parent
6e78c875c2
commit
fba6089db0
2 changed files with 4 additions and 2 deletions
|
@ -346,9 +346,10 @@ class SettingsListener {
|
|||
/**
|
||||
* Prevent enabling both Pay Later messaging and PayPal vaulting
|
||||
*
|
||||
* @return void
|
||||
* @throws RuntimeException When API request fails.
|
||||
*/
|
||||
public function listen_for_vaulting_enabled() {
|
||||
public function listen_for_vaulting_enabled(): void {
|
||||
if ( ! $this->is_valid_site_request() || State::STATE_ONBOARDED !== $this->state->current_state() ) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -168,7 +168,8 @@ class WcSubscriptionsModule implements ModuleInterface {
|
|||
return $methods;
|
||||
}
|
||||
|
||||
if ( ! is_wc_endpoint_url( 'order-pay' ) ) {
|
||||
//phpcs:disable WordPress.Security.NonceVerification.Recommended
|
||||
if ( ! ( isset( $_GET['change_payment_method'] ) && is_wc_endpoint_url( 'order-pay' ) ) ) {
|
||||
return $methods;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue