addressed jshint failures, fixed #898