lib/i18n/js.rb in i18n-js-3.0.0.rc10 vs lib/i18n/js.rb in i18n-js-3.0.0.rc11

- old
+ new

@@ -63,10 +63,11 @@ # deep_merge! given result with result for fallback locale def self.merge_with_fallbacks!(result) I18n.available_locales.each do |locale| fallback_locales = FallbackLocales.new(fallbacks, locale) fallback_locales.each do |fallback_locale| - result[locale] = Utils.deep_merge(result[fallback_locale], result[locale] || {}) + # `result[fallback_locale]` could be missing + result[locale] = Utils.deep_merge(result[fallback_locale] || {}, result[locale] || {}) end end end def self.filtered_translations