mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 23:58:31 -05:00
Disable in development (js)
This commit is contained in:
parent
cb395662d0
commit
15905be788
1 changed files with 8 additions and 4 deletions
|
@ -78,12 +78,16 @@ module JsLocaleHelper
|
|||
|
||||
site_locale = SiteSetting.default_locale.to_sym
|
||||
|
||||
if locale_sym == :en
|
||||
if Rails.env.development?
|
||||
translations = load_translations(locale_sym)
|
||||
elsif locale_sym == site_locale || site_locale == :en
|
||||
translations = load_translations_merged(locale_sym, :en)
|
||||
else
|
||||
translations = load_translations_merged(locale_sym, site_locale, :en)
|
||||
if locale_sym == :en
|
||||
translations = load_translations(locale_sym)
|
||||
elsif locale_sym == site_locale || site_locale == :en
|
||||
translations = load_translations_merged(locale_sym, :en)
|
||||
else
|
||||
translations = load_translations_merged(locale_sym, site_locale, :en)
|
||||
end
|
||||
end
|
||||
|
||||
message_formats = strip_out_message_formats!(translations[locale_str]['js'])
|
||||
|
|
Loading…
Reference in a new issue