Mongodb – How to add custom vallidator for Node.js / app.patch method findByIdAndUpdate
this question about backend development node.js how do i update a database data by using object id please help me to learn those things custom validator app.patch("/users/:id", async (req, res) => { try { const user = await User.findByIdAndUpdate(req.params.id, req.body,…