mirror of
https://github.com/discourse/discourse.git
synced 2025-09-06 10:50:21 +08:00
FIX: I18n Fallbacks were not applying correctly
This commit is contained in:
parent
47410f1b99
commit
d1ebb9d0b5
5 changed files with 42 additions and 28 deletions
|
@ -81,9 +81,9 @@ module JsLocaleHelper
|
|||
|
||||
site_locale = SiteSetting.default_locale.to_sym
|
||||
|
||||
if Rails.env.development?
|
||||
translations = load_translations(locale_sym, force: true)
|
||||
else
|
||||
# if Rails.env.development?
|
||||
# translations = load_translations(locale_sym, force: true)
|
||||
# else
|
||||
if locale_sym == :en
|
||||
translations = load_translations(locale_sym)
|
||||
elsif locale_sym == site_locale || site_locale == :en
|
||||
|
@ -91,7 +91,7 @@ module JsLocaleHelper
|
|||
else
|
||||
translations = load_translations_merged(locale_sym, site_locale, :en)
|
||||
end
|
||||
end
|
||||
# end
|
||||
|
||||
message_formats = strip_out_message_formats!(translations[locale_str]['js'])
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue