Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZ.J. van de Weg <git@zjvandeweg.nl>2017-03-06 13:50:32 +0300
committerZ.J. van de Weg <git@zjvandeweg.nl>2017-03-06 16:34:47 +0300
commit75123fa9f706a6ab7cdd5dba4393ad9d8bac0947 (patch)
tree39beb2ae628d37005d3be7d09957ea4616421a77 /lib/api/jobs.rb
parent194223476b8df57a56ba096c7a300d51d2e3e750 (diff)
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.rb21
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