some jshint improvements