Don't pass document as argument when not needed