I am using this command to update the document.
order = await db.collection("orders").findOneAndUpdate({ order_id: req.body.ORDERID }, {$set: { payment_status: "Paid", paymentInfo: JSON.stringify(myrequest) }})
console.log(order)
But the document is not updated instead return this in console
lastErrorObject: { n: 0, updatedExisting: false },
value: null,
ok: 1,
'$clusterTime': {
clusterTime: new Timestamp({ t: 1663565745, i: 13 }),
signature: {
hash: new Binary(Buffer.from("5165sd1vdsvds651vds5vvs5dvdsvdskvjdsv, "hex"), 0),
keyId: new Long("1451151132154123165")
}