From 2d1cdcc473701d06945dec4bb69bf96f3ab76dcb Mon Sep 17 00:00:00 2001 From: Hidayet Ok Date: Wed, 23 Dec 2020 01:37:10 +0300 Subject: [PATCH] Translated sentences converted into magento standard --- Helper/Cart.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Helper/Cart.php b/Helper/Cart.php index d407e90..b8edc0f 100644 --- a/Helper/Cart.php +++ b/Helper/Cart.php @@ -49,20 +49,19 @@ public function applyCoupon(\Magento\Quote\Model\Quote $quote, string $coupon): catch (LocalizedException $e) { $this->messageManager->addError( - __("Discount code $coupon couldn't be applied: " . - $e->getMessage()) + __("Discount code %1 couldn't be applied: %2",$coupon,$e->getMessage()) ); } catch (\Exception $e) { $this->messageManager->addError( - __("Discount code $coupon couldn't be applied or is invalid") + __("Discount code %1 couldn't be applied or is invalid",$coupon) ); } if ($quote->getCouponCode() != $coupon) { $this->messageManager->addError( - __("Discount code $coupon is invalid. Verify that it's correct and try again.") + __("Discount code %1 is invalid. Verify that it's correct and try again.",$coupon) ); } }