From 9e150b7fbed15eb4cd6f2df3763ab3ac828abac8 Mon Sep 17 00:00:00 2001 From: wangruidong <940853815@qq.com> Date: Thu, 20 Nov 2025 14:43:04 +0800 Subject: [PATCH] fix: One login lock, resulting in two logs --- apps/authentication/mixins.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/authentication/mixins.py b/apps/authentication/mixins.py index 5b1e03dda..0314fc08d 100644 --- a/apps/authentication/mixins.py +++ b/apps/authentication/mixins.py @@ -211,7 +211,7 @@ class AuthPreCheckMixin: logger.warning('Ip was blocked' + ': ' + username + ':' + ip) exception = errors.BlockLoginError(username=username, ip=ip, request=self.request) if raise_exception: - raise errors.BlockLoginError(username=username, ip=ip, request=self.request) + raise exception else: return exception