Update auth.dart

This commit is contained in:
Tobe O 2017-02-25 09:08:47 -05:00 committed by GitHub
parent 318dcfe42a
commit 52fedf6d17

View file

@ -11,9 +11,9 @@ class AuthController extends Controller {
serializer(User user) async => user.id; serializer(User user) async => user.id;
/// Attempt to log a user in /// Attempt to log a user in
verifier(UserService Users) { verifier(UserService userService) {
return (String username, String password) async { return (String username, String password) async {
List<User> users = await Users.index({'query':{'username': username}}); List<User> users = await userService.index({'query':{'username': username}});
if (users.isNotEmpty) { if (users.isNotEmpty) {
var hash = hashPassword(password); var hash = hashPassword(password);