![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/old/patches/composer/ |
diff --git a/vendor/magento/module-email/Model/Template/Filter.php b/vendor/magento/module-email/Model/Template/Filter.php index 1a7c3683820a..586cb485ee1f 100644 --- a/vendor/magento/module-email/Model/Template/Filter.php +++ b/vendor/magento/module-email/Model/Template/Filter.php @@ -618,6 +618,12 @@ public function transDirective($construction) } $text = __($text, $params)->render(); + + $pattern = '/{{.*?}}/'; + do { + $text = preg_replace($pattern, '', (string)$text); + } while (preg_match($pattern, $text)); + return $this->applyModifiers($text, $modifiers); } diff --git a/vendor/magento/framework/Filter/DirectiveProcessor/VarDirective.php b/vendor/magento/framework/Filter/DirectiveProcessor/VarDirective.php index f2fe398c3848..78034d70ba51 100644 --- a/vendor/magento/framework/Filter/DirectiveProcessor/VarDirective.php +++ b/vendor/magento/framework/Filter/DirectiveProcessor/VarDirective.php @@ -55,6 +55,11 @@ public function process(array $construction, Template $filter, array $templateVa $result = $this->filterApplier->applyFromRawParam($construction['filters'], $result); } + $pattern = '/{{.*?}}/'; + do { + $result = preg_replace($pattern, '', (string)$result); + } while (preg_match($pattern, $result)); + return $result; }