fixing several types of jshint suggestions, but left a few in .jshintrc