fixed jshint error and test error