You can find an $\eta$ for each $[-a,a]$, but there is not necessarily one for $\lim_{a\rightarrow\infty}[-a,a]=\mathbb{R}$, yes (because $g$ is not necessarily uniformly continuous on $\mathbb{R}$). A limiting argument might still work, but the issue is more subtle. It might work if you construct a sequence for each $a$ and then show that they have a pointwise limit as $a\rightarrow\infty$ (not sure if that's true, but it would suffice).