avoid creation of a document when it already exists