From b058cf15f0ef79fcc4d24f2952e5d55ff0be46cc Mon Sep 17 00:00:00 2001 From: Christopher Allan Webber Date: Sun, 3 Apr 2011 18:32:29 -0500 Subject: [PATCH] We should use one instead of find_one to really make sure there's only one such user in the database --- mediagoblin/auth/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mediagoblin/auth/views.py b/mediagoblin/auth/views.py index 03c31576..d56dfa43 100644 --- a/mediagoblin/auth/views.py +++ b/mediagoblin/auth/views.py @@ -79,7 +79,7 @@ def login(request): login_failed = False if request.method == 'POST' and login_form.validate(): - user = request.db.User.find_one( + user = request.db.User.one( {'username': request.POST['username']}) if user and user.check_login(request.POST['password']):