tomas / needle

Nimble, streamable HTTP client for Node.js. With proxy, iconv, cookie, deflate & multipart support.
https://www.npmjs.com/package/needle
MIT License
1.62k stars 235 forks source link

Multiple Files Upload Renames Input Field #409

Open zotakk4o opened 2 years ago

zotakk4o commented 2 years ago

Hi Team, there seems to be a problem sending multiple files at the same field(part) name.

var data = { images: [{ file: 'linux.png', content_type: 'image/png' }, {
file: 'linux(1).png', content_type: 'image/png' }] } Request with this data will be sent as: { images[0]: ..., images[1]: ... }

Can you please inform me on whether this can be changed?