Skip to content

Commit

Permalink
Merge branch 'roberttaylor426/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
dherault committed Apr 13, 2022
2 parents 6db368c + bcddae5 commit 10afe5e
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,13 @@ export default class LambdaProxyIntegrationEventV2 {
const requestTime = formatToClfTime(received)
const requestTimeEpoch = received

const cookies = Object.entries(this.#request.state).map(
([key, value]) => `${key}=${value}`,
const cookies = Object.entries(this.#request.state).flatMap(
([key, value]) => {
if (Array.isArray(value)) {
return value.map((v) => `${key}=${v}`)
}
return `${key}=${value}`
},
)

return {
Expand Down

0 comments on commit 10afe5e

Please sign in to comment.