mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-28 19:29:38 +00:00
shorten long line of lib/redmine/i18n.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@20432 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
a2894b61bf
commit
f3f884854c
@ -133,7 +133,11 @@ module Redmine
|
||||
end
|
||||
|
||||
def find_language(lang)
|
||||
@@languages_lookup ||= valid_languages.inject({}) {|k, v| k[v.to_s.downcase] = v; k }
|
||||
@@languages_lookup ||=
|
||||
valid_languages.inject({}) do |k, v|
|
||||
k[v.to_s.downcase] = v
|
||||
k
|
||||
end
|
||||
@@languages_lookup[lang.to_s.downcase]
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user