diff --git a/src/app/code/community/Smile/ElasticSearch/Helper/Data.php b/src/app/code/community/Smile/ElasticSearch/Helper/Data.php index 5566cd61..65b9351b 100644 --- a/src/app/code/community/Smile/ElasticSearch/Helper/Data.php +++ b/src/app/code/community/Smile/ElasticSearch/Helper/Data.php @@ -85,7 +85,10 @@ public function getLanguageCodeByLocaleCode($localeCode) */ public function getLanguageCodeByStore($store = null) { - return $this->getLanguageCodeByLocaleCode($this->getLocaleCode($store)); + if (!isset($this->_languageCodes[$store->getStoreId()])) { + $this->_languageCodes[$store->getStoreId()] = $this->getLanguageCodeByLocaleCode($this->getLocaleCode($store)); + } + return $this->_languageCodes[$store->getStoreId()]; } /**