diff --git a/src/Core/ShopControl.php b/src/Core/ShopControl.php index 56f6cf336..32855f9bf 100644 --- a/src/Core/ShopControl.php +++ b/src/Core/ShopControl.php @@ -22,12 +22,12 @@ class ShopControl extends ShopControl_parent /** * @param StandardException $exception */ - protected function _handleBaseException($exception) // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore + protected function handleBaseException($exception) // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore { if ($exception instanceof PayPalException) { $this->handleCustomPayPalException($exception); } else { - parent::_handleBaseException($exception); + parent::handleBaseException($exception); } } // @codeCoverageIgnore @@ -41,7 +41,7 @@ public function handleCustomPayPalException(PayPalException $exception): void } elseif ($exception instanceof Redirect) { $this->handlePayPalRedirectException($exception, false); } else { - parent::_handleBaseException($exception); + parent::handleBaseException($exception); } } // @codeCoverageIgnore diff --git a/views/twig/extensions/themes/default/layout/base.html.twig b/views/twig/extensions/themes/default/layout/base.html.twig index 8a21b3ff0..abf342741 100644 --- a/views/twig/extensions/themes/default/layout/base.html.twig +++ b/views/twig/extensions/themes/default/layout/base.html.twig @@ -4,31 +4,21 @@ {{ parent() }} {% if oViewConf.isPayPalCheckoutActive() %} {% set className = oViewConf.getTopActiveClassName() %} - {% if oViewConf.isPayPalExpressPaymentEnabled() and - ((className == 'order' and not oViewConf.isPayPalACDCSessionActive()) or (className != 'order' and className != 'payment')) and - ( - (oxcmp_basket.getProductsCount() and oViewConf.showPayPalMiniBasketButton()) or - (className == 'details' and oViewConf.showPayPalProductDetailsButton()) or - (className == 'basket' and oViewConf.showPayPalBasketButton()) - ) - %} - - - {% set sCountryRestriction = oViewConf.getCountryRestrictionForPayPalExpress() %} - {% if sCountryRestriction %} - - {% endif %} - {% elseif className == 'order' and oViewConf.isPayPalACDCSessionActive() %} - - {% elseif className == 'payment' %} - - {% elseif oViewConf.isPayPalBannerActive() and (className == 'start' or className == 'search' or className == 'details' or className == 'alist' or className == 'basket') %} - + {% set sFileMTime = oViewConf.getModulePath('osc_paypal', 'js/paypal-frontend.min.js') %} + + + {% set sCountryRestriction = oViewConf.getCountryRestrictionForPayPalExpress() %} + {% if sCountryRestriction %} + {% endif %} {% if submitCart %}