Fixed jslint and jshint issues.