From e415571a6e766e961cd49a0ac92576c460a49e4d Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Wed, 1 Nov 2023 21:13:36 +0000 Subject: Add latest changes from gitlab-org/gitlab@master --- lib/api/helpers.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib/api/helpers.rb') diff --git a/lib/api/helpers.rb b/lib/api/helpers.rb index a7e0a551283..f17474394e2 100644 --- a/lib/api/helpers.rb +++ b/lib/api/helpers.rb @@ -397,6 +397,10 @@ module API authorize! :update_build, user_project end + def authorize_cancel_builds! + authorize! :cancel_build, user_project + end + def require_repository_enabled!(subject = :global) not_found!("Repository") unless user_project.feature_available?(:repository, current_user) end -- cgit v1.2.3