This project is archived and is in readonly mode.
Custom I18n Configuration Setup: example of setting config.i18n.load_path in config/application.rb causes an error
Reported by Tadatoshi Takahashi | March 21st, 2010 @ 09:24 PM
In config/application.rb, there is an example code to add a
load_path for I18n, i.e.
config.i18n.load_path += Dir[Rails.root.join('my', 'locales',
'*.{rb,yml}')]
When I uncommented this line and tried to start the server by
"rails server", starting the server failed with an error message
"config/application.rb:29:in []': can't convert Pathname into
String (TypeError)".
As a work around, I changed it to
config.i18n.load_path += Dir[File.join(Rails.root, 'my', 'locales',
'*.{rb,yml}')]
Then the server started successfully without the error.
Comments and changes to this ticket
-
José Valim March 26th, 2010 @ 11:12 PM
- State changed from new to resolved
Yup, the comment as fixed, thanks!
-
Ryan Bigg October 9th, 2010 @ 10:01 PM
- Tag cleared.
- Importance changed from to Low
Automatic cleanup of spam.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>