diff --git a/lib/redmine/i18n.rb b/lib/redmine/i18n.rb index a79b4fc68..c2beafefb 100644 --- a/lib/redmine/i18n.rb +++ b/lib/redmine/i18n.rb @@ -177,13 +177,11 @@ module Redmine # Custom backend based on I18n::Backend::Simple with the following changes: # * available_locales are determined by looking at translation file names class Backend < ::I18n::Backend::Simple - module Implementation - # Get available locales from the translations filenames - def available_locales - @available_locales ||= begin - redmine_locales = Dir[Rails.root / 'config' / 'locales' / '*.yml'].map { |f| File.basename(f, '.yml').to_sym } - super & redmine_locales - end + # Get available locales from the translations filenames + def available_locales + @available_locales ||= begin + redmine_locales = Dir[Rails.root / 'config' / 'locales' / '*.yml'].map { |f| File.basename(f, '.yml').to_sym } + super & redmine_locales end end