Skip to content
This repository has been archived by the owner on Aug 30, 2021. It is now read-only.

Commit

Permalink
Merge pull request #139 from macsj200/patch-2
Browse files Browse the repository at this point in the history
Genericize invalid username or password message
  • Loading branch information
amoshaviv committed Oct 7, 2014
2 parents 8519f6b + aeb0272 commit e5e2616
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions config/strategies/local.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@ module.exports = function() {
}
if (!user) {
return done(null, false, {
message: 'Unknown user'
message: 'Unknown user or invalid password'
});
}
if (!user.authenticate(password)) {
return done(null, false, {
message: 'Invalid password'
message: 'Unknown user or invalid password'
});
}

return done(null, user);
});
}
));
};
};

0 comments on commit e5e2616

Please sign in to comment.