If $f$ is a nonzero rational function on a locally Noetherian normal scheme and $f$ has no poles, show that $f$ is regular.
The hint is to use algebraic Hartogs' lemma which is the following
Suppose A is a integrally closed Noetherian integral domain. Then $$ A = \bigcap_{ p \text{ }\text{codimension 1}} A_p $$
I can prove this when then scheme is an affine normal scheme, but I don't know how to prove the general case.