fix most jshint warnings