fixing the documents and attachments