fixed errors from jshint