diff options
author | Sean McGivern <sean@gitlab.com> | 2017-02-06 12:17:26 +0000 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2017-02-06 12:17:26 +0000 |
commit | a08bbcbc4417baf0316e77501b44e5db6d75fe9a (patch) | |
tree | 7a0cdcc765d1d0ffdcd3aedf541621b784b8036d /app/views/projects/snippets | |
parent | 572fb0be9b1d45437b7c0ed1000399657f471ec7 (diff) | |
download | gitlab-ce-a08bbcbc4417baf0316e77501b44e5db6d75fe9a.tar.gz |
Don't render snippet actions for logged-out userssnippet-spam-fix
Diffstat (limited to 'app/views/projects/snippets')
-rw-r--r-- | app/views/projects/snippets/_actions.html.haml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/views/projects/snippets/_actions.html.haml b/app/views/projects/snippets/_actions.html.haml index e2a5107a883..dde2e2b644d 100644 --- a/app/views/projects/snippets/_actions.html.haml +++ b/app/views/projects/snippets/_actions.html.haml @@ -1,3 +1,5 @@ +- return unless current_user + .hidden-xs - if can?(current_user, :update_project_snippet, @snippet) = link_to edit_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-grouped" do |