diff options
author | Z.J. van de Weg <git@zjvandeweg.nl> | 2017-03-06 11:50:32 +0100 |
---|---|---|
committer | Z.J. van de Weg <git@zjvandeweg.nl> | 2017-03-06 14:34:47 +0100 |
commit | 75123fa9f706a6ab7cdd5dba4393ad9d8bac0947 (patch) | |
tree | 39beb2ae628d37005d3be7d09957ea4616421a77 /lib/api/jobs.rb | |
parent | 194223476b8df57a56ba096c7a300d51d2e3e750 (diff) | |
download | gitlab-ce-75123fa9f706a6ab7cdd5dba4393ad9d8bac0947.tar.gz |
Incorporate review, drop old endpoint
The endpoint dropped, get ':id/repository/commits/:sha/jobs', should be
replace by a new endpoint.
Diffstat (limited to 'lib/api/jobs.rb')
-rw-r--r-- | lib/api/jobs.rb | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/lib/api/jobs.rb b/lib/api/jobs.rb index b48574e173f..33c05e8aa63 100644 --- a/lib/api/jobs.rb +++ b/lib/api/jobs.rb @@ -40,27 +40,6 @@ module API user_can_download_artifacts: can?(current_user, :read_build, user_project) end - desc 'Get jobs for a specific commit of a project' do - success Entities::Job - end - params do - requires :sha, type: String, desc: 'The SHA id of a commit' - use :optional_scope - use :pagination - end - get ':id/repository/commits/:sha/jobs' do - authorize_read_builds! - - return not_found! unless user_project.commit(params[:sha]) - - pipelines = user_project.pipelines.where(sha: params[:sha]) - builds = user_project.builds.where(pipeline: pipelines).order('id DESC') - builds = filter_builds(builds, params[:scope]) - - present paginate(builds), with: Entities::Job, - user_can_download_artifacts: can?(current_user, :read_build, user_project) - end - desc 'Get a specific job of a project' do success Entities::Job end |