diff options
author | Yorick Peterse <yorickpeterse@gmail.com> | 2018-09-25 14:24:28 +0300 |
---|---|---|
committer | Yorick Peterse <yorickpeterse@gmail.com> | 2018-09-25 14:24:28 +0300 |
commit | a1ee365843dccc265557904051e8bd51d5f54488 (patch) | |
tree | 38741180b8b10000d8e40a0056653ac45db5a90c /app/controllers | |
parent | cdff2c664131bc1b20685ee2fc0372c11ee028f8 (diff) | |
parent | 74ae135888f55c17f6c53bcba9c1ca979a33724e (diff) |
Merge branch 'mk/improve-usage-of-request-store' into 'master'
Resolve "Provide NullStore for RequestStore"
Closes #51718
See merge request gitlab-org/gitlab-ce!21848
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/concerns/with_performance_bar.rb | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/app/controllers/concerns/with_performance_bar.rb b/app/controllers/concerns/with_performance_bar.rb index c12839c7bbd..77c3d476ac6 100644 --- a/app/controllers/concerns/with_performance_bar.rb +++ b/app/controllers/concerns/with_performance_bar.rb @@ -10,11 +10,7 @@ module WithPerformanceBar def peek_enabled? return false unless Gitlab::PerformanceBar.enabled?(current_user) - if RequestStore.active? - RequestStore.fetch(:peek_enabled) { cookie_or_default_value } - else - cookie_or_default_value - end + Gitlab::SafeRequestStore.fetch(:peek_enabled) { cookie_or_default_value } end private |