Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add PATCH /camels/:id with find and update API
Alternative patch implementation using Mongoose `findByIdAndUpdate`: https://mongoosejs.com/docs/api.html#model_Model.findByIdAndUpdate Notice: The `new` determines whether to return the new (i.e., updated) version (default: false) Caveats: Mongoose is in the process of changing their API: Automattic/mongoose#6922 (comment) To fix the deprecation warnings, we need to set: ```js mongoose.set('useFindAndModify', false); ```
- Loading branch information