[multipart/form-data] Payload is parsed incorrectly
- Dominant language
- JavaScript
- Stars
- 14.8k
- Forks
- 1.4k
- Avg merge
- 22d 3h
- Merged PRs (30d)
- 1
Description
#### Context
* *hapi version*: 20.3.0
#### How can we help?
I'm working with the multipart/form-data on hapi (version 20.3.0), the request payload is not parsed correctly for array and nested object.
Here is my request payload that i got
My route
```js
server.route({
method: 'POST',
path: '/onboarding/{draft_id}',
options: {
handler: controller.create.bind(controller),
validate: {
// payload: createValidator,
failAction: (_, __, err) => badRequest(err.message),
},
payload: {
allow: 'multipart/form-data',
maxBytes: 20 * 1000 * 1000, // max payload to be 20MB in size.
multipart: {
output: 'data',
},
parse: true,
},
tags: [
'create-onboarding',
'onboarding',
],
description: 'Create Onboarding',
},
});
```
Contributor guide
Assessment
This issue has not been assessed yet.