diff --git a/debug_toolbar/middleware.py b/debug_toolbar/middleware.py index 862a38f9e..aae699757 100644 --- a/debug_toolbar/middleware.py +++ b/debug_toolbar/middleware.py @@ -126,9 +126,9 @@ def __init__(self, get_response: GetResponse): markcoroutinefunction(self) def __call__(self, request: HttpRequest) -> HttpResponse: - # Decide whether the toolbar is active for this request. if self.async_mode: return self.__acall__(request) + # Decide whether the toolbar is active for this request. show_toolbar = get_show_toolbar(async_mode=self.async_mode)