diff options
author | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-04 02:05:42 +0100 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-04-04 02:05:42 +0100 |
commit | 1e15444ae6dda02744db42d08c817252953c7b1f (patch) | |
tree | fbc15aed4220716b8844546601320c32624a4e7e /app/models | |
parent | 90c8bb8301b4bc3268a5fa4ea8bddafbc29d6871 (diff) | |
download | gitlab-ce-1e15444ae6dda02744db42d08c817252953c7b1f.tar.gz |
Cleanup & tests for UserAccess#can_create_tag?
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/concerns/protected_ref.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/concerns/protected_ref.rb b/app/models/concerns/protected_ref.rb index a04dea0bc55..ab28eb19b64 100644 --- a/app/models/concerns/protected_ref.rb +++ b/app/models/concerns/protected_ref.rb @@ -8,7 +8,7 @@ module ProtectedRef delegate :matching, :matches?, :wildcard?, to: :ref_matcher - def self.matching_refs_accesible_to(ref, user, action: :push) + def self.protected_ref_accessible_to?(ref, user, action: :push) access_levels_for_ref(ref, action: action).any? do |access_level| access_level.check_access(user) end |