From 5e520ebb49d0f5105128759caafd5010456078ba Mon Sep 17 00:00:00 2001 From: Alex P Date: Thu, 30 Nov 2023 08:39:08 +0200 Subject: [PATCH] Fix disable-funding field access Fixed usage of the `disabled-funding` field usage because It can be missing, it is added only if there are disabled funding sources. --- modules/ppcp-blocks/src/PayPalPaymentMethod.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ppcp-blocks/src/PayPalPaymentMethod.php b/modules/ppcp-blocks/src/PayPalPaymentMethod.php index fe0a381c6..b914c528e 100644 --- a/modules/ppcp-blocks/src/PayPalPaymentMethod.php +++ b/modules/ppcp-blocks/src/PayPalPaymentMethod.php @@ -214,7 +214,7 @@ class PayPalPaymentMethod extends AbstractPaymentMethodType { } } - $disabled_funding_sources = explode( ',', $script_data['url_params']['disable-funding'] ) ?: array(); + $disabled_funding_sources = explode( ',', $script_data['url_params']['disable-funding'] ?? '' ) ?: array(); $funding_sources = array_values( array_diff( array_keys( $this->all_funding_sources ),