Fix multi-part sending with aiohttp in webhooks.

This commit is contained in:
Rapptz 2017-08-22 00:26:43 -04:00
parent 754f3a2ae9
commit 8eb6fa0329

View File

@ -145,6 +145,7 @@ class AsyncWebhookAdapter(WebhookAdapter):
if multipart:
file = multipart.pop('file', None)
data = aiohttp.FormData()
if file:
data.add_field('file', file[0], filename=file[1], content_type=file[2])
for key, value in multipart.items():