Use Rails.application.config.i18n.load_path for adding plugin locales (#12753).

Patch by Takeshi Yaegashi.

git-svn-id: http://svn.redmine.org/redmine/trunk@12482 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2014-01-05 14:46:22 +00:00
parent 77ac3b7891
commit 1f50862586
1 changed files with 1 additions and 1 deletions

View File

@ -79,7 +79,7 @@ module Redmine #:nodoc:
# Adds plugin locales if any # Adds plugin locales if any
# YAML translation files should be found under <plugin>/config/locales/ # YAML translation files should be found under <plugin>/config/locales/
::I18n.load_path += Dir.glob(File.join(p.directory, 'config', 'locales', '*.yml')) Rails.application.config.i18n.load_path += Dir.glob(File.join(p.directory, 'config', 'locales', '*.yml'))
# Prepends the app/views directory of the plugin to the view path # Prepends the app/views directory of the plugin to the view path
view_path = File.join(p.directory, 'app', 'views') view_path = File.join(p.directory, 'app', 'views')