Beta - Mongoose Challenges - Create and Save a Record of a Model

I had the same problem, you have to use the save method inside the createAndSavePerson function:

var createAndSavePerson = function(done) {
 var person = new Person({name: 'Ben', age: 23, favouriteFoods: ['tuna', 'bread']})
 person.save((err, data)=>{
  if (err) return done(err)
  return done(null, data)
 }
}

13 Likes