I am looking at Theorem 2 from Evans PDE 2nd Edition chapter 8.4.1 about Lagrange Multipliers. Here he is trying to prove there is a real number $\lambda$ such that
$$\int_U Du\cdot Dv\;dx=\lambda\int_U g(u)v\;dx$$
where $u\in H_0^1(U)$ is the minimizer of a functional $I[\cdot]$ subject to an integral constraint $J(w)=\int_U G(w)\;dx=0$. The part I am confused about is in the case where he assumes $g(u)=0$ almost everywhere ($g=G'$ for $G$ smooth). He argues that
$$D(G(u))=g(u)Du=0$$
thus since $U$ is assumed to be smooth, bounded, and connected, $G(u)$ must be constant. Since $J(u)=0$, we must have $G(u)=0$ almost everywhere. So far so good. From here, he asserts that "as $u=0$ on $\partial U$ in the trace sense, it follows that $G(0)=0$"
This is where I am stuck. If $u$ were continuous, then it would be immediate since $u$ would have to be close to zero on some set near the boundary, so if $G(0)\neq0$ then this would violate $J(u)=0$. But we only know that it is zero on the boundary in the trace sense. My attempts to use density by $C_c^\infty(U)$ functions have not worked, since there is no guarantee that the approximating functions stay near to zero at the boundary in any uniform way to break the condition $J(u)=0$ in the same way.
It seems this should be rather straightforward since Evans doesn't elaborate on this detail but I seem to be missing something obvious. Any ideas?