Only refresh site settings once on initialization.

This commit is contained in:
Guo Xiang Tan 2017-10-12 14:12:18 +08:00
parent 630f7bfba2
commit 4e89d3f778
4 changed files with 0 additions and 8 deletions

View File

@ -27,11 +27,6 @@ class SiteSetting < ActiveRecord::Base
end
end
# `current` hash is not populated everytime when load a site setting
# in order to support locale default. Instead, we simply `refresh!` once.
# This should only affects the spec in which you should populate `current`
refresh!
client_settings << :available_locales
def self.available_locales

View File

@ -59,9 +59,6 @@ Discourse::Application.configure do
end
config.after_initialize do
SiteSetting.defaults.set_regardless_of_locale(:port, 3000)
SiteSetting.refresh!
if ENV['BULLET']
Bullet.enable = true
Bullet.rails_logger = true