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