Skip to content

Commit

Permalink
fix(typescript): include a header object when transforming `Content…
Browse files Browse the repository at this point in the history
…-Type` and `Content-Length` to `headers.content-type` and `headers.content-length`
  • Loading branch information
mamodom committed Nov 18, 2018
1 parent ebea33d commit 0b9cc37
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion scripts/lib/get-routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,14 @@ function getRoutes () {
indexes.forEach(i => endpoint.params.splice(i, 1))
endpoint.params.unshift(
Object.assign(contentLengthParam, { name: 'headers.content-length' }),
Object.assign(contentTypeParam, { name: 'headers.content-type' })
Object.assign(contentTypeParam, { name: 'headers.content-type' }),
{
name: 'headers',
location: 'headers',
required: true,
type: 'object',
description: 'Request headers containing `content-type` and `content-length`'
}
)
}

Expand Down

0 comments on commit 0b9cc37

Please sign in to comment.