From 2e5a241777ef0bb0d76420d39bf3be41e16e042a Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Thu, 18 Feb 2016 08:59:13 +0100 Subject: New management of the token for the account confirmation. --- src/web/views/api/common.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/web/views/api') diff --git a/src/web/views/api/common.py b/src/web/views/api/common.py index 3476cad9..c155a254 100644 --- a/src/web/views/api/common.py +++ b/src/web/views/api/common.py @@ -54,8 +54,7 @@ def authenticate(func): if auth is not None: user = User.query.filter( User.nickname == auth.username).first() - if user and user.check_password(auth.password) \ - and user.activation_key == "": + if user and user.check_password(auth.password) and user.enabled: g.user = user logged_in = True if logged_in: -- cgit