diff --git a/market/models/user.rb b/market/models/user.rb index 5aff57f332..d5c3da7905 100644 --- a/market/models/user.rb +++ b/market/models/user.rb @@ -178,7 +178,7 @@ class User "status" => "enabled" ) - if check_password(user, password) + if user && check_password(user, password) return user else return nil