Mongoose document update error
问题 Been working with node and mongoose lately and I enjoyed it until I had to update a model. Here is what I'm doing: module.exports.update = (post, cb) -> Post.update _id: post._id, post, (err, data) -> cb(err, data) So I thought it'll be a easy as saving a new post but it's complaining with error: err: 'Mod on _id not allowed' I tried to delete post._id before passing it to my update method, but it didn't work and I couldn't find any good examples on how to do it except one that looks a bit