Fixing jshint warnings

Fixed some jshint warnings for missing semicolons and mixed tabs and spaces. Not sure I caught all of them to be honest though.