namshi / cuzzle

This library let's you dump a Guzzle request to a cURL command for debug and log purpose.
https://github.com/namshi/cuzzle
331 stars 68 forks source link

Logger shows only the first file in a request with more than one file #9

Open stuzzo opened 9 years ago

stuzzo commented 9 years ago

Hi, I'm doing a request with one text field (named JSON) and two files (named file and icon).

This is the log output:

curl 'http://test.local/app_dev.php/test/post' \   -A 'Guzzle/5.3.0 curl/7.22.0 PHP/5.5.27-1+deb.sury.org~precise+1' \   -H 'Content-Type: multipart/form-data' -X POST \   -d '--55af920568ab9 Content-Disposition: form-data; name="JSON"  {"title":"Title","filename":"video.mp4","startdate":"22-07-2015","starttime":"02:49","enddate":"31-12-2016","endtime":"23:59","https":"yes"} --55af920568ab9 Content-Disposition: form-data; name="icon"; filename="fok_original.jpg" Content-Type: image/jpeg  '

I added a var_dump on controller and $request->request->all() shows me the JSON field and $request->files has two elements, file and icon.

Anyone can replicate this?

Thank you.