From b7979ad48ede8896c83117b2dd67f5190fc525c2 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Mon, 23 May 2022 20:29:05 +0200 Subject: [PATCH] Revert "events: ignore silk SQLQuery object" This reverts commit a26f25ccd61202e92ca48cede18fb155c65f69a2. Signed-off-by: Jens Langhammer --- authentik/events/middleware.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/authentik/events/middleware.py b/authentik/events/middleware.py index fc98b09b5..b0bd71ae6 100644 --- a/authentik/events/middleware.py +++ b/authentik/events/middleware.py @@ -25,12 +25,10 @@ IGNORED_MODELS = [ AuthenticatedSession, StaticToken, ] -try: +if settings.DEBUG: from silk.models import Request, Response, SQLQuery IGNORED_MODELS += [Request, Response, SQLQuery] -except ImportError: - pass IGNORED_MODELS = tuple(IGNORED_MODELS)