diff --git a/CatalogUrlManager.php b/CatalogUrlManager.php index 8d7b103..f4871da 100755 --- a/CatalogUrlManager.php +++ b/CatalogUrlManager.php @@ -5,6 +5,7 @@ use artweb\artbox\ecommerce\models\Category; use artweb\artbox\ecommerce\models\Product; use artweb\artbox\ecommerce\models\ProductVariant; + use yii\helpers\VarDumper; use yii\web\HttpException; use yii\web\UrlRuleInterface; @@ -23,6 +24,12 @@ */ public function parseRequest($manager, $request) { + /** + * Fast url fix + */ + if (!preg_match('@^\/(ru|ua).*@i', $request->url) && $request->url !== '/') { + throw new HttpException(404, 'Page not found'); + } $pathInfo = $request->getPathInfo(); $paths = explode('/', $pathInfo); -- libgit2 0.21.4