Updated error messages

This commit is contained in:
Sahat Yalkabov
2014-01-12 15:31:17 -05:00
parent 2179994e24
commit 3dc90ac05b
2 changed files with 3 additions and 3 deletions

View File

@ -27,7 +27,7 @@ passport.use(new LocalStrategy({ usernameField: 'email' }, function(email, passw
if(isMatch) {
return done(null, user);
} else {
return done(null, false, { message: 'Your username or password is incorrect' });
return done(null, false, { message: 'Invalid email or password.' });
}
});
});

View File

@ -75,11 +75,11 @@ exports.postSignup = function(req, res, next) {
var errors = [];
if (!req.body.email) {
errors.push('Email is missing.');
errors.push('Email cannot be blank.');
}
if (!req.body.password) {
errors.push('Password is missing.');
errors.push('Password cannot be blank.');
}
if (req.body.password !== req.body.confirmPassword) {