Lint all the codebase to sensible defaults

We now have proper linting across the codebase.

From our new(ish) .jshint file grunt will now run a lint and fail the build if you don't match the hintfile.

Fixed all occurrences where lint was failing.