Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2017-07-18 13:04:20 +0300
committerLin Jen-Shin <godfat@godfat.org>2017-07-18 13:04:20 +0300
commit3922b803290ecccdb232c2c150ee249ba2b57c97 (patch)
treea05eb6d68525dcafb81be08c266e7b8c68dc9de1 /lib/gitlab/user_access.rb
parentffc5b29bd0f02676bdc05ec6185d115d6705cd8f (diff)
Rename the methods to make it fit with current name
Diffstat (limited to 'lib/gitlab/user_access.rb')
-rw-r--r--lib/gitlab/user_access.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/gitlab/user_access.rb b/lib/gitlab/user_access.rb
index a30dfe0f6bf..8e91ee7287c 100644
--- a/lib/gitlab/user_access.rb
+++ b/lib/gitlab/user_access.rb
@@ -2,7 +2,7 @@ module Gitlab
class UserAccess
extend Gitlab::Cache::RequestCache
- request_store_wrap_key do
+ request_cache_key do
[user&.id, project&.id]
end
@@ -34,7 +34,7 @@ module Gitlab
true
end
- request_store_wrap def can_create_tag?(ref)
+ request_cache def can_create_tag?(ref)
return false unless can_access_git?
if ProtectedTag.protected?(project, ref)
@@ -44,7 +44,7 @@ module Gitlab
end
end
- request_store_wrap def can_delete_branch?(ref)
+ request_cache def can_delete_branch?(ref)
return false unless can_access_git?
if ProtectedBranch.protected?(project, ref)
@@ -54,7 +54,7 @@ module Gitlab
end
end
- request_store_wrap def can_push_to_branch?(ref)
+ request_cache def can_push_to_branch?(ref)
return false unless can_access_git?
if ProtectedBranch.protected?(project, ref)
@@ -66,7 +66,7 @@ module Gitlab
end
end
- request_store_wrap def can_merge_to_branch?(ref)
+ request_cache def can_merge_to_branch?(ref)
return false unless can_access_git?
if ProtectedBranch.protected?(project, ref)