-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
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
Bug/resolve locale #156
base: master
Are you sure you want to change the base?
Bug/resolve locale #156
Conversation
+1 Can this PR be merged please ? |
Hi @qpautrat thanks for the patch, could you please rebase with the new master? |
@acasademont Done ! |
@qpautrat thanks but i'm afraid there must be something wrong here, in your PR there are also some of my commits and the diff is not clear. Can you please squash and make sure there's only 1 commit and the diff is clear? Thank! :D |
4e9c49c
to
3f02d09
Compare
@acasademont Is this ok now ? I'm really sorry, i'm not used to do that, kind of beginner here. 😕 |
@@ -192,6 +192,12 @@ private function matchI18n(array $params, $url) | |||
$params['_route'] = substr($params['_route'], $pos + strlen(I18nLoader::ROUTING_PREFIX)); | |||
} | |||
|
|||
foreach($this->hostMap as $locale => $host) { | |||
if ($host == $this->context->getHost()) { | |||
$this->context->setParameter('_locale', $locale); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should break the loop here once the locale is found
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks !
Thanks! Could you fix the small thing I mentioned and squash all the commits please? |
2412b14
to
eec5fe8
Compare
@acasademont Done. |
what about this PR ? Could it be merged please ? |
Resolve locale from current host
See #128