For testing purposes I would like to empty a capped collection. It's not possible to do so using remove().
I was trying to issue this using MyModel.collection.<methods-from-mongodb>
or mongoose.connection.<again-some-variations>
.
What is the correct way and is it possible in the currecnt version 4.4.20
?
MyModel.collection.drop()
Most helpful comment
MyModel.collection.drop()