Fixed a lot of small things on the bug list