Add error checking to db.printCollectionStats()