Fix issue with command queuing in mongoose

This fixes the `TypeError: Cannot read property 'event' of undefined` error produced when collection commands get queued in mongoose.