How to disable console.logs?

Hamid Alaei V. shared this question 5 years ago

The logs that are automatically printed into the console after insert() and update() seem to slow down performance. Is there a way to disable them?

Replies (1)


There is not way to turn off these logs for insert and update. To be compatible with the mongo shell, both methods call print internally.

There is a work-around solution, use insertOne/InsertMany and updateOne/updateMany to replace insert/update method.

Leave a Comment
Attach a file