summaryrefslogtreecommitdiff
path: root/lib/api/entities.rb
diff options
context:
space:
mode:
authorTomasz Maczukin <tomasz@maczukin.pl>2017-03-16 05:18:37 +0100
committerKamil Trzcinski <ayufan@ayufan.eu>2017-03-20 09:40:36 +0100
commit9267a9b19d6c7e090c286e9d922c71fe64190a47 (patch)
treef51fca2645c5fcd5b92b0104df54436137cb3ac5 /lib/api/entities.rb
parente79ab1115bf6ab4776678a379f7d507455d867c0 (diff)
downloadgitlab-ce-9267a9b19d6c7e090c286e9d922c71fe64190a47.tar.gz
Send token of depenent job
Artifacts download for authorization is using a job token of job to which the artifact belongs. In APIv1 the token was sent with dependent jobs details and in APIv4 it was designed to also contain it. However I forgot about this parameter while working on `/api/v4/jobs/request` endpoint. This commit adds a missing parameter which is required for APIv4 to work properly.
Diffstat (limited to 'lib/api/entities.rb')
-rw-r--r--lib/api/entities.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/entities.rb b/lib/api/entities.rb
index 0a12ee72d49..29c640ddb19 100644
--- a/lib/api/entities.rb
+++ b/lib/api/entities.rb
@@ -768,7 +768,7 @@ module API
end
class Dependency < Grape::Entity
- expose :id, :name
+ expose :id, :name, :token
expose :artifacts_file, using: ArtifactFile, if: ->(job, _) { job.artifacts? }
end