From 08cf8b878a9919b95b44ef69b04830532d487c24 Mon Sep 17 00:00:00 2001 From: Jeroen Date: Tue, 8 May 2018 17:32:50 +0200 Subject: [PATCH] Don't recalculate tax for every price on category page --- app/code/Magento/Tax/Model/Config.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/code/Magento/Tax/Model/Config.php b/app/code/Magento/Tax/Model/Config.php index b30e5afb85142..09212ce90bf58 100644 --- a/app/code/Magento/Tax/Model/Config.php +++ b/app/code/Magento/Tax/Model/Config.php @@ -832,12 +832,12 @@ public function getInfoUrl($store = null) * If it necessary will be returned conversion type (minus or plus) * * @param null|int|string|Store $store - * @return bool + * @return bool|int * @SuppressWarnings(PHPMD.CyclomaticComplexity) */ public function needPriceConversion($store = null) { - $res = false; + $res = 0; $priceIncludesTax = $this->priceIncludesTax($store) || $this->getNeedUseShippingExcludeTax(); if ($priceIncludesTax) { switch ($this->getPriceDisplayType($store)) { @@ -845,7 +845,7 @@ public function needPriceConversion($store = null) case self::DISPLAY_TYPE_BOTH: return self::PRICE_CONVERSION_MINUS; case self::DISPLAY_TYPE_INCLUDING_TAX: - $res = true; + $res = false; break; default: break;