Complete saveScrapState function with WriteConcern