Email signup for angularized, user.js controller modified so that username can be stored upon signup

This commit is contained in:
terakilobyte
2015-01-09 21:33:50 -05:00
parent 02eb3b5914
commit 11bc776ffb
2 changed files with 5 additions and 2 deletions

View File

@ -109,7 +109,10 @@ exports.postEmailSignup = function(req, res, next) {
var user = new User({
email: req.body.email,
password: req.body.password
password: req.body.password,
profile : {
username: req.body.username
}
});
User.findOne({ email: req.body.email }, function(err, existingUser) {