Correct createDocument