summaryrefslogtreecommitdiff
path: root/app/serializers/pipeline_entity.rb
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2017-08-02 16:58:28 -0700
committerStan Hu <stanhu@gmail.com>2017-08-02 16:58:28 -0700
commit408df2edcbd5f3f93ef5541bac9de2b71ba4f0ea (patch)
tree708ae61f9683b48f436f7577d1fad98f30e100fc /app/serializers/pipeline_entity.rb
parent3f81586ef0ab20533b8da1213bd9f60e1786dbaa (diff)
parentfaa2a123911eaf84bb57163ea7af759d4632601b (diff)
downloadgitlab-ce-408df2edcbd5f3f93ef5541bac9de2b71ba4f0ea.tar.gz
Merge branch 'master' into sh-headless-chrome-support
Diffstat (limited to 'app/serializers/pipeline_entity.rb')
-rw-r--r--app/serializers/pipeline_entity.rb13
1 files changed, 3 insertions, 10 deletions
diff --git a/app/serializers/pipeline_entity.rb b/app/serializers/pipeline_entity.rb
index 6d1fd9d459f..c4f000b0ca3 100644
--- a/app/serializers/pipeline_entity.rb
+++ b/app/serializers/pipeline_entity.rb
@@ -10,10 +10,7 @@ class PipelineEntity < Grape::Entity
expose :created_at, :updated_at
expose :path do |pipeline|
- namespace_project_pipeline_path(
- pipeline.project.namespace,
- pipeline.project,
- pipeline)
+ project_pipeline_path(pipeline.project, pipeline)
end
expose :flags do
@@ -48,15 +45,11 @@ class PipelineEntity < Grape::Entity
expose :commit, using: CommitEntity
expose :retry_path, if: -> (*) { can_retry? } do |pipeline|
- retry_namespace_project_pipeline_path(pipeline.project.namespace,
- pipeline.project,
- pipeline.id)
+ retry_project_pipeline_path(pipeline.project, pipeline)
end
expose :cancel_path, if: -> (*) { can_cancel? } do |pipeline|
- cancel_namespace_project_pipeline_path(pipeline.project.namespace,
- pipeline.project,
- pipeline.id)
+ cancel_project_pipeline_path(pipeline.project, pipeline)
end
expose :yaml_errors, if: -> (pipeline, _) { pipeline.has_yaml_errors? }