we still need to cast the document.