summaryrefslogtreecommitdiff
path: root/app/views/projects/commit
diff options
context:
space:
mode:
authorMark Fletcher <mark@gitlab.com>2017-01-02 20:51:57 +0000
committerMark Fletcher <mark@gitlab.com>2017-03-07 20:05:33 +0530
commitb5b448934563b0b3237b6b2e6e168c012b012097 (patch)
tree8d7f7b977b9d53ab60d764bb89e15d5790057316 /app/views/projects/commit
parentdf55d35ffd33fe97e669a227dd4666044e8cc65b (diff)
downloadgitlab-ce-b5b448934563b0b3237b6b2e6e168c012b012097.tar.gz
Don't show links to tag a commit for non permitted users
* Show tag link for users that can push code * Don't show tag link for guests and non-authenticated users
Diffstat (limited to 'app/views/projects/commit')
-rw-r--r--app/views/projects/commit/_commit_box.html.haml5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/views/projects/commit/_commit_box.html.haml b/app/views/projects/commit/_commit_box.html.haml
index 4d0b7a5ca85..d001e01609a 100644
--- a/app/views/projects/commit/_commit_box.html.haml
+++ b/app/views/projects/commit/_commit_box.html.haml
@@ -34,8 +34,9 @@
= revert_commit_link(@commit, namespace_project_commit_path(@project.namespace, @project, @commit.id), has_tooltip: false)
%li.clearfix
= cherry_pick_commit_link(@commit, namespace_project_commit_path(@project.namespace, @project, @commit.id), has_tooltip: false)
- %li.clearfix
- = link_to "Tag", new_namespace_project_tag_path(@project.namespace, @project, ref: @commit)
+ - if can_collaborate_with_project?
+ %li.clearfix
+ = link_to "Tag", new_namespace_project_tag_path(@project.namespace, @project, ref: @commit)
%li.divider
%li.dropdown-header
Download