summaryrefslogtreecommitdiff
path: root/app/views/projects/_last_push.html.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/projects/_last_push.html.haml')
-rw-r--r--app/views/projects/_last_push.html.haml7
1 files changed, 4 insertions, 3 deletions
diff --git a/app/views/projects/_last_push.html.haml b/app/views/projects/_last_push.html.haml
index 6a1035d2dc7..f6d396c8127 100644
--- a/app/views/projects/_last_push.html.haml
+++ b/app/views/projects/_last_push.html.haml
@@ -13,6 +13,7 @@
#{time_ago_with_tooltip(event.created_at)}
- .flex-right
- = link_to new_mr_path_from_push_event(event), title: _("New merge request"), class: "btn btn-info btn-sm qa-create-merge-request" do
- #{ _('Create merge request') }
+ - if can?(current_user, :create_merge_request_in, event.project.default_merge_request_target)
+ .flex-right
+ = link_to new_mr_path_from_push_event(event), title: _("New merge request"), class: "btn btn-info btn-sm qa-create-merge-request" do
+ #{ _('Create merge request') }