/** * @return bool|int */ public function getStoreId() { if (!$this->isInitialized) { $countryCode = (string) $this->country->getCountryCode(); try { $this->storeId = $this->rule->getStoreId($countryCode); $this->storeId = $this->permanentRule->updateStoreId($this->storeId, $countryCode); } catch (\Exception $e) { $this->logger->critical($e); } $this->isInitialized = true; } return $this->storeId; }