From be7ffbcb904fde7d5eade37b38ff419070bbf142 Mon Sep 17 00:00:00 2001 From: Jean-Romain Garnier Date: Fri, 17 Apr 2020 17:03:51 +0200 Subject: [PATCH] Revert "Allow suspended users to login" This reverts commit 91c51c50df1d947cb451a4a037cb2b651a973ba0. --- users/models.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/users/models.py b/users/models.py index 09877ae1..36884115 100755 --- a/users/models.py +++ b/users/models.py @@ -335,7 +335,6 @@ class User( self.state == self.STATE_ACTIVE or self.state == self.STATE_NOT_YET_ACTIVE or self.state == self.STATE_EMAIL_NOT_YET_CONFIRMED - or self.state == self.STATE_SUSPENDED or ( allow_archived and self.state in (self.STATE_ARCHIVE, self.STATE_FULL_ARCHIVE) @@ -345,7 +344,7 @@ class User( def set_active(self): """Enable this user if he subscribed successfully one time before Reenable it if it was archived - Do nothing if suspended, disabled or waiting for email confirmation""" + Do nothing if disabled or waiting for email confirmation""" if self.state == self.STATE_NOT_YET_ACTIVE: if self.facture_set.filter(valid=True).filter( Q(vente__type_cotisation="All") | Q(vente__type_cotisation="Adhesion")