Commit 93ce2296 authored by Yorick Peterse's avatar Yorick Peterse

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
......@@ -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?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment