Skip to content

Commit

Permalink
There are some lint errors that needed to be cleaned up.
Browse files Browse the repository at this point in the history
  • Loading branch information
brentlintner committed Aug 30, 2012
1 parent 72d70ec commit 3a6f531
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion lib/cli.js
Expand Up @@ -49,7 +49,7 @@ function _searchFile(name, dir) {
return dir === parent ? null : _searchFile(name, parent);
}

function _findConfig(target) {
function _findConfig() {
var name = ".jshintrc",
projectConfig = _searchFile(name),
homeConfig = path.normalize(path.join(process.env.HOME, name));
Expand Down
4 changes: 2 additions & 2 deletions lib/hint.js
Expand Up @@ -30,8 +30,8 @@ function _lint(file, results, config, data) {

// remove custom node-jshint option
if (config.globals) {
globals = config.globals;
delete config.globals;
globals = config.globals;
delete config.globals;
}

if (!jshint.JSHINT(buffer, config, globals)) {
Expand Down
2 changes: 1 addition & 1 deletion lib/reporters/default.js
@@ -1,5 +1,5 @@
module.exports = {
reporter: function (results, data) {
reporter: function (results) {
var len = results.length,
str = '',
file, error;
Expand Down
2 changes: 1 addition & 1 deletion lib/reporters/non_error.js
@@ -1,7 +1,7 @@
/*jshint node: true */
module.exports =
{
reporter: function (results, data, done) {
reporter: function (results, data) {
var len = results.length,
str = '',
file, error, globals, unuseds;
Expand Down
3 changes: 1 addition & 2 deletions tasks/test.js
Expand Up @@ -21,6 +21,5 @@ module.exports = function () {
}
});

jasmine.executeSpecsInFolder(__dirname + "/../test/unit/", function (runner, log) {
}, verbose, colored);
jasmine.executeSpecsInFolder(__dirname + "/../test/unit/", null, verbose, colored);
};
4 changes: 2 additions & 2 deletions test/unit/cli.js
Expand Up @@ -68,11 +68,11 @@ describe("cli", function () {
path = require('path'),
home = path.join(process.env.HOME, '.jshintrc');

spyOn(path, "existsSync").andCallFake(function (path, encoding) {
spyOn(path, "existsSync").andCallFake(function (path) {
return path.match(home) ? true : false;
});

spyOn(fs, "readFileSync").andCallFake(function (path, encoding) {
spyOn(fs, "readFileSync").andCallFake(function (path) {
if (path === home) {
return JSON.stringify(config);
} else {
Expand Down

0 comments on commit 3a6f531

Please sign in to comment.