Skip to content

Commit

Permalink
[hapi] temp fix for payload.multipart breaking change
Browse files Browse the repository at this point in the history
  • Loading branch information
watson committed Dec 15, 2020
1 parent 6348063 commit 448040d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/core/server/http/http_server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,15 @@ export class HttpServer {
auth: this.getAuthOption(authRequired),
app: kibanaRouteOptions,
tags: tags ? Array.from(tags) : undefined,
// @ts-expect-error Types are outdated and doesn't allow `payload.multipart` to be `true`
payload: [allow, maxBytes, output, parse, timeout?.payload].some((x) => x !== undefined)
? {
allow,
maxBytes,
output,
parse,
timeout: timeout?.payload,
multipart: true, // TODO: Figure out what the default value should be
}
: undefined,
timeout: {
Expand Down

0 comments on commit 448040d

Please sign in to comment.