Persist the doc, if there is one