Wednesday, February 8, 2012

Re: [Rails] Call for help: Rails Reserved Words Wiki

Not sure if worth adding, but I hit some weeks ago a nice issue when
translating a site that contained "NO" translations in YAML, like
this:

https://gist.github.com/1707858

"NO" meant as in "Norway". I18n.t('country.NO') was returning
"translation missing: en.country.NO".

So, "YES" and "NO" are reserved words at this level. The fix was to
add quotes like this:

country:
"NO": "Norway"


Best regards,
Rafael Fernández López.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate