public
Description: A Ruby on Rails plugin with a web interface for translating I18n texts
Homepage: http://developer.newsdesk.se/2009/01/21/translate-new-rails-i18n-plugin-with-a-nice-web-ui
Clone URL: git://github.com/newsdesk/translate.git
translate / init.rb
100644 9 lines (7 sloc) 0.345 kb
1
2
3
4
5
6
7
8
9
require 'translate'
 
# TODO: Use new method available_locales once Rails is upgraded, see:
# http://github.com/svenfuchs/i18n/commit/411f8fe7c8f3f89e9b6b921fa62ed66cb92f3af4
def I18n.valid_locales
  I18n.backend.send(:init_translations) unless I18n.backend.initialized?
  backend.send(:translations).keys.reject { |locale| locale == :root }
end