We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Used following plugin to fix
<?php declare(strict_types=1); namespace Vendor\PhproTranslations\Plugin; use Magento\Framework\App\Config\ScopeConfigInterface; use Magento\Store\Model\StoreManager; use Phpro\Translations\Model\Translation\Source\Locales as SourceLocales; class Locales { private const XML_PATH_LOCALE = 'general/locale/code'; public function __construct( private readonly ScopeConfigInterface $scopeConfig, private readonly StoreManager $storeManager, ) { } /** * @param SourceLocales $subject * @param callable $proceed * @return array */ public function aroundToOptionArray(SourceLocales $subject, callable $proceed): array { $stores = $this->storeManager->getStores(); $result = []; foreach ($stores as $store) { $locale = $this->scopeConfig->getValue(self::XML_PATH_LOCALE, 'stores', $store->getId()); $result[] = ['value' => $locale, 'label' => $store->getName()]; } return $result; } }
The text was updated successfully, but these errors were encountered:
@MaximGns could you verify your issue has been resolved with the latest release?
Sorry, something went wrong.
No branches or pull requests
Used following plugin to fix
The text was updated successfully, but these errors were encountered: