diff --git a/passbook/root/asgi.py b/passbook/root/asgi.py index ec5598b60..32751d15e 100644 --- a/passbook/root/asgi.py +++ b/passbook/root/asgi.py @@ -87,7 +87,7 @@ 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["more_body"]: + 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)