From 1bc7968e52c7b6006002e5c8c3713b8ad2b75548 Mon Sep 17 00:00:00 2001 From: Daniel Dudzic Date: Mon, 3 Jun 2024 17:49:00 +0200 Subject: [PATCH] Add WPML compatibility to the settings --- modules/ppcp-wc-gateway/src/Settings/Settings.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/ppcp-wc-gateway/src/Settings/Settings.php b/modules/ppcp-wc-gateway/src/Settings/Settings.php index ebd6f1081..25fcb808d 100644 --- a/modules/ppcp-wc-gateway/src/Settings/Settings.php +++ b/modules/ppcp-wc-gateway/src/Settings/Settings.php @@ -154,8 +154,10 @@ class Settings implements ContainerInterface { 'woocommerce-paypal-payments' ), ); + foreach ( $defaults as $key => $value ) { if ( isset( $this->settings[ $key ] ) ) { + $this->settings[ $key ] = apply_filters( 'woocommerce_paypal_payments_settings_value', $this->settings[ $key ], $key ); continue; } $this->settings[ $key ] = $value;