Skip to content

Commit

Permalink
support version 1.9.0 of i18n due to ruby-i18n/i18n#573
Browse files Browse the repository at this point in the history
  • Loading branch information
mpantel committed Jan 27, 2022
1 parent 2c8bea7 commit 975d473
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion i18n-active_record.gemspec
Expand Up @@ -19,7 +19,7 @@ Gem::Specification.new do |s|
s.require_path = 'lib'
s.rubyforge_project = '[none]'

s.add_dependency 'i18n', '>= 0.5.0'
s.add_dependency 'i18n', '>= 1.9.0'

s.add_development_dependency 'appraisal'
s.add_development_dependency 'bundler'
Expand Down
4 changes: 2 additions & 2 deletions lib/i18n/backend/active_record.rb
Expand Up @@ -97,9 +97,9 @@ def lookup(locale, key, scope = [], options = {})
result.first.value
else
result = result.inject({}) do |hash, translation|
hash.deep_merge build_translation_hash_by_key(key, translation)
Utils.deep_merge(hash, build_translation_hash_by_key(key, translation))
end
result.deep_symbolize_keys
Utils.deep_symbolize_keys(result)
end
end

Expand Down

0 comments on commit 975d473

Please sign in to comment.