Spock icon indicating copy to clipboard operation
Spock copied to clipboard

Multiple file upload, but only one file in request body

Open aherrmann opened this issue 7 years ago • 2 comments

Multiple file upload seems to not be handled correctly. If a user selects multiple files to upload on a file input field, such as the following, then the request body will contain only one file associated with the input field.

<input multiple name="files" id="files" type="file">

From a quick look at the code, maybe this part should use HM.fromListWith (<>) and a HashMap Text [UploadedFile]?

aherrmann avatar May 09 '18 12:05 aherrmann

Sounds like a bug! The fix seems reasonable to me, although I would prefer to use Vector instead of list. Could you write a test (and possibly a fix) for this? :)

agrafix avatar May 10 '18 04:05 agrafix

Running into this too.

flyingllama87 avatar Sep 18 '19 06:09 flyingllama87