Help with a continuity proof

D is a nonempty bounded subset of R. Let a=inf D and b=sup D.

Let f:D-->R be a uniformly continuous function.

Let g(x)={f(x) if x in D; $\displaystyle \alpha$ if x=a; $\displaystyle \beta$ if x=b

Prove that $\displaystyle \alpha, \beta$ exist such that g(x) is continuous.

Well, g(x) is continuous on (a,b) because f(x) is continuous, by hypothesis.

Can I take the limit as x-->a of f from the right to find $\displaystyle \alpha$ and the limit as x-->b of f from the left to find $\displaystyle \beta$, thus making g(x) continuous?