Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/master' into DEV-36…
Browse files Browse the repository at this point in the history
…2-add-github-actions

# Conflicts:
#	Helper/StoreUrl.php
  • Loading branch information
RanaMuhammadIrshad committed Jun 4, 2024
2 parents 497df8a + 546c83e commit acae034
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
11 changes: 7 additions & 4 deletions Helper/StoreUrl.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,7 @@
/** @phpstan-ignore-next-line */
use MageWorx\SeoBase\Helper\StoreUrl as MageworxStoreUrl;

/** @phpstan-ignore-next-line */
if (class_exists(MageWorxStoreUrl::class)) {

/** @phpstan-ignore-next-line */
if (class_exists(MageworxStoreUrl::class)) {
class StoreUrl extends MageworxStoreUrl
{
protected function isUseStoreCodeInUrl(StoreInterface $store): bool
Expand All @@ -24,7 +21,13 @@ protected function isUseStoreCodeInUrl(StoreInterface $store): bool
$storeId = (int)$store->getId();

return !($store->hasDisableStoreInUrl() && $store->getDisableStoreInUrl())
// @phpstan-ignore-next-line
&& $this->configDataLoader->getConfigValue(Store::XML_PATH_STORE_IN_URL, $storeId);
}
}
} else {
class StoreUrl

Check failure on line 29 in Helper/StoreUrl.php

View workflow job for this annotation

GitHub Actions / phpcs / M2 Coding Standard

Each class must be in a file by itself

Check failure on line 29 in Helper/StoreUrl.php

View workflow job for this annotation

GitHub Actions / phpcs / M2 Coding Standard

Each class must be in a file by itself
{

}
}
3 changes: 1 addition & 2 deletions etc/di.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,5 @@
<type name="Magento\Store\Model\Store">
<plugin name="hide_default_store_code" type="CustomGento\DefaultStoreCodeRemover\Plugin\Store\HideDefaultStoreCodePlugin"/>
</type>

<preference for="MageWorx\SeoBase\Helper\StoreUrl" type="CustomGento\DefaultStoreCodeRemover\Helper\StoreUrl"/>
</config>
</config>

0 comments on commit acae034

Please sign in to comment.