satisfy jshint and minor changes