Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Problem in FrameworkBundle\Translation\Translator.php when using culture in locale #7824

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

Closed
josdewitte opened this issue Apr 23, 2013 · 1 comment

Comments

@josdewitte
Copy link

File:

D:\Projects\ClimbCheck\climbing\vendor\symfony\symfony\src\Symfony\Bundle\FrameworkBundle\Translation\Translator.php

When using en-us as fallback locale, on line 106 and 112 str_replace('-','') or something alike should be used. Else the generated file will contain something like
'$catalogueEn-Us = new MessageCatalogue .....'

Please fix!!

fabpot added a commit that referenced this issue Jun 24, 2013
This PR was submitted for the 2.3 branch but it was merged into the 2.2 branch instead (closes #8310).

Discussion
----------

[FrameworkBundle] Fixed variable name used in translation cache

This simply fixes the `$catalogueXXX` variable name used in the translation cache files in case the user use locales such as `en-US`, the generated variable's name was `$catalogueEn-Us`, with this fix it will be `$catalogueEnUs`.

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #7824
| License       | MIT
| Doc PR        | -

Commits
-------

e50399c [FrameworkBundle] Fixed variable name used in translation cache
@jfsimon jfsimon closed this as completed Jul 11, 2013
@jfsimon
Copy link
Contributor

jfsimon commented Jul 11, 2013

Fixed by #8310

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants