I have a document \"owner\" that can have \"n\" number of camps and camps have \"instructors\" and instructors have \"classes\". Earlier I tried accomplishing this with nested a
var newObject = {usuario: req.body.usuario, fecha: req.body.fecha, edit: req.body.edit}; await Documentos.findByIdAndUpdate(id, { deleted_doc: true, $push: { history: newObject } }); res.json({ status: 'Documentos Updated' });