Fix CurrentSettings autoload bug in development.

Error: A copy of Gitlab::CurrentSettings has been removed from the module tree but is still active
This commit is contained in:
Jason Lee
2016-02-08 15:28:48 +01:00
committed by Rémy Coutable
parent 9fdd605fd2
commit e4d276816a
+2 -2
View File
@@ -7,8 +7,8 @@ module Gitlab
settings = nil
if connect_to_db?
settings = ApplicationSetting.current
settings ||= ApplicationSetting.create_from_defaults unless ActiveRecord::Migrator.needs_migration?
settings = ::ApplicationSetting.current
settings ||= ::ApplicationSetting.create_from_defaults unless ActiveRecord::Migrator.needs_migration?
end
settings || fake_application_settings