diff --git a/lib/api/builds.rb b/lib/api/builds.rb index 9b7a3f12d2b846a8459f1d46ad6355fe090ce597..5752ef2725bfcb7488d98c820cbdd5f464faad07 100644 --- a/lib/api/builds.rb +++ b/lib/api/builds.rb @@ -132,7 +132,7 @@ module API # example Request: # delete /projects/:id/build/:build_id/content delete ':id/builds/:build_id/content' do - authorize_manage_builds! + authorize_update_builds! build = get_build(params[:build_id]) return not_found!(build) unless build diff --git a/spec/factories/ci/builds.rb b/spec/factories/ci/builds.rb index af6e27569c0157d20323f7ad120c039ccbf79b7b..41497c2ce80b7bc3882d898d6fefbbe0ac56e917 100644 --- a/spec/factories/ci/builds.rb +++ b/spec/factories/ci/builds.rb @@ -67,7 +67,7 @@ FactoryGirl.define do build.artifacts_metadata = fixture_file_upload(Rails.root.join('spec/fixtures/ci_build_artifacts_metadata.gz'), - ' application/x-gzip') + 'application/x-gzip') build.save! end