Sunday, 9 April 2017

Difference between insert new data using instance of new object or using .create

What's the diference between these two ways?

Example:

var user = new User({
    user.name = "Blabla",
    user.password = "blabla"
});


User.create({name:req.body.blabla, password:req.body.blablabla},callback func)



via Gustavo Dias

No comments:

Post a Comment