root: fix asgi formatting

This commit is contained in:
Jens Langhammer 2020-11-24 12:36:54 +01:00
parent 6573d2e8f6
commit 2de4023d43
1 changed files with 3 additions and 1 deletions

View File

@ -87,7 +87,9 @@ class ASGILogger:
if b"Content-Length" in headers:
self.content_length += int(headers.get(b"Content-Length", b"0"))
if message["type"] == "http.response.body" and not message.get("more_body", None):
if message["type"] == "http.response.body" and not message.get(
"more_body", None
):
runtime = int((time() - self.start) * 10 ** 6)
self.log(runtime)
await send(message)