invariant: body after request is processed must be binary

This commit is contained in:
Raúl Sampedro 2017-04-25 12:00:27 +02:00
parent 1036242064
commit 85acddddba

View File

@ -173,8 +173,7 @@ class HttpProtocol(asyncio.Protocol):
self.request.body.append(body) self.request.body.append(body)
def on_message_complete(self): def on_message_complete(self):
if self.request.body: self.request.body = b''.join(self.request.body)
self.request.body = b''.join(self.request.body)
self._request_handler_task = self.loop.create_task( self._request_handler_task = self.loop.create_task(
self.request_handler( self.request_handler(