diff --git a/lib/internal/Magento/Framework/App/Config.php b/lib/internal/Magento/Framework/App/Config.php index 01db8483142ba..9e64effe54b0f 100644 --- a/lib/internal/Magento/Framework/App/Config.php +++ b/lib/internal/Magento/Framework/App/Config.php @@ -95,6 +95,7 @@ public function isSetFlag($path, $scope = ScopeConfigInterface::SCOPE_TYPE_DEFAU /** * Invalidate cache by type + * Clean scopeCodeResolver * * @return void */ @@ -103,6 +104,7 @@ public function clean() foreach ($this->types as $type) { $type->clean(); } + $this->scopeCodeResolver->clean(); } /** diff --git a/lib/internal/Magento/Framework/App/Config/ScopeCodeResolver.php b/lib/internal/Magento/Framework/App/Config/ScopeCodeResolver.php index 4596f317eb18d..95608b37bb4dd 100644 --- a/lib/internal/Magento/Framework/App/Config/ScopeCodeResolver.php +++ b/lib/internal/Magento/Framework/App/Config/ScopeCodeResolver.php @@ -58,4 +58,14 @@ public function resolve($scopeType, $scopeCode) $this->resolvedScopeCodes[$scopeType][$scopeCode] = $resolverScopeCode; return $resolverScopeCode; } + + /** + * Clean resolvedScopeCodes, store codes may have been renamed + * + * @return void + */ + public function clean() + { + $this->resolvedScopeCodes = []; + } }