diff options
Diffstat (limited to 'app')
-rw-r--r-- | app/models/application_setting.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/application_setting.rb b/app/models/application_setting.rb index 9a14954b4a7..33069d66d78 100644 --- a/app/models/application_setting.rb +++ b/app/models/application_setting.rb @@ -98,6 +98,10 @@ class ApplicationSetting < ActiveRecord::Base Rails.cache.delete(CACHE_KEY) end + def self.cached + Rails.cache.fetch(CACHE_KEY) + end + def self.create_from_defaults create( default_projects_limit: Settings.gitlab['default_projects_limit'], |