Minor fixes. Happy with this code now.

4 jobs for master