Tweaking the code for fixing some dumb errors.

:beers: