diff options
author | Reuben Pereira <rpereira@gitlab.com> | 2019-08-07 21:40:36 +0300 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2019-08-07 21:40:36 +0300 |
commit | af4a597d3fb687ed2841bb755403f66cf131bdff (patch) | |
tree | 45b6188b5a67d4372b4073c41a420119d6300a89 /lib | |
parent | d02003cf951692cc243b7ee512de2139e99f0c4c (diff) |
Save instance administration project id in DB
- This will make it easy to identify the project even if admins change
the name of the project or move it.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/current_settings.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/gitlab/current_settings.rb b/lib/gitlab/current_settings.rb index 32d5e4b9ea3..6ce47650562 100644 --- a/lib/gitlab/current_settings.rb +++ b/lib/gitlab/current_settings.rb @@ -7,6 +7,11 @@ module Gitlab Gitlab::SafeRequestStore.fetch(:current_application_settings) { ensure_application_settings! } end + def expire_current_application_settings + ::ApplicationSetting.expire + Gitlab::SafeRequestStore.delete(:current_application_settings) + end + def clear_in_memory_application_settings! @in_memory_application_settings = nil end |