clonn / slack-node-sdk

slack.com, slack, node sdk
MIT License
167 stars 32 forks source link

Changed form key in POST to force multipart/form-data request #34

Closed simonwillcock closed 8 years ago

simonwillcock commented 8 years ago

The Slack API requires that files uploaded must use multipart/form-data otherwise you are returned the invalid_array_arg error.

Changing the request form key to formData will make the request library use multipart/form-data as seen in the example in the readme

nobuta commented 8 years ago

:+1:

kevinburkeshyp commented 8 years ago

would be nice to have a test for this :(

kevinburkeshyp commented 8 years ago

merged as a4e98fc0e9be04741589bae6128a9529f4d039d1, thanks!

simonwillcock commented 8 years ago

Ah, yeah sorry I didn't think about a test! I'm still learning the ins and outs of unit testing. But thanks for the merge :)