Skip to content

Commit 156c506

Browse files
committed
Removed unused condition
1 parent a4c6599 commit 156c506

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

debug_toolbar/middleware.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,8 @@ async def dispatch(
7474
content_type = response.headers.get("Content-Type", "")
7575
is_html = content_type.startswith("text/html")
7676

77-
if (
78-
not (is_html or content_type == "application/json")
79-
or "gzip" in response.headers.get("Accept-Encoding", "")
80-
or request.scope.get("endpoint") is None
77+
if not (is_html or content_type == "application/json") or (
78+
"gzip" in response.headers.get("Accept-Encoding", "")
8179
):
8280
return response
8381

0 commit comments

Comments
 (0)