Fixed syntax error.

This commit is contained in:
Martin Edenhofer 2013-02-13 00:21:56 +01:00
parent acad651fef
commit 5b9ba8611d

View file

@ -82,19 +82,21 @@ class User < ApplicationModel
if user_auth if user_auth
# remember last login date # remember last login date
user.update_last_login user_auth.update_last_login
# reset login failed # reset login failed
user.login_failed = 0 user_auth.login_failed = 0
user.save user_auth.save
return user_auth return user_auth
end end
} }
# set login failed +1 # set login failed +1
user.login_failed = user.login_failed + 1 if !user_auth && user
user.save user.login_failed = user.login_failed + 1
user.save
end
# auth failed # auth failed
sleep 1 sleep 1