diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-25 19:35:00 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-26 12:05:46 +0300 |
commit | d06df33daa0013bfec624ee0ab3ef72e92b0f1cf (patch) | |
tree | 2ab851924152376747a84152f312fe6ed20c7672 /app/views | |
parent | a448e4a62c165820b08949f3136ef01397b9f1a7 (diff) |
Ensure current user can retry a build before showing the 'Retry' button
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/projects/builds/_sidebar.html.haml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/projects/builds/_sidebar.html.haml b/app/views/projects/builds/_sidebar.html.haml index dc57b49f27a..b89183c40dc 100644 --- a/app/views/projects/builds/_sidebar.html.haml +++ b/app/views/projects/builds/_sidebar.html.haml @@ -40,7 +40,7 @@ .block{ class: ("block-first" if !@build.coverage && !(can?(current_user, :read_build, @project) && (@build.artifacts? || @build.artifacts_expired?))) } .title Build details - - if @build.retryable? + - if can?(current_user, :update_build, @build) && @build.retryable? = link_to "Retry", retry_namespace_project_build_path(@project.namespace, @project, @build), class: 'pull-right', method: :post - if @build.merge_request %p.build-detail-row |