Skip to content
Snippets Groups Projects
Verified Commit 93ce2296 authored by Yorick Peterse's avatar Yorick Peterse
Browse files

Use tag_exists? in GitAccess#protected_tag?

This removes the need for retrieving the entire list of tags just to
check if a specific one exists.
parent 6e47a192
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -176,7 +176,7 @@ module Gitlab
end
 
def protected_tag?(tag_name)
project.repository.tag_names.include?(tag_name)
project.repository.tag_exists?(tag_name)
end
 
def user_allowed?
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment