Comparing version 0.14.0 to 0.14.1
@@ -184,3 +184,3 @@ /** | ||
if (printResults(engine, result.results, currentOptions.format, currentOptions.outputFile)) { | ||
return result.errorCount; | ||
return result.errorCount ? 1 : 0; | ||
} else { | ||
@@ -187,0 +187,0 @@ return 1; |
@@ -92,3 +92,3 @@ /** | ||
* @param {Number} line - line number | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -102,3 +102,3 @@ function markCheckLine(line) { | ||
* @param {ASTNode} checkNode - targeted node | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -113,3 +113,3 @@ function markCheck(checkNode) { | ||
* @param {Number} indents - indents count to push | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -124,3 +124,3 @@ function markPush(node, indents) { | ||
* @param {Number} outdents - count of outedents in targeted line | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -134,3 +134,3 @@ function markPop(node, outdents) { | ||
* @param {ASTNode} node - targeted node | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -146,3 +146,3 @@ function markPushAlt(node) { | ||
* @param {Number} indents - indent count to push | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -159,3 +159,3 @@ function markPushAndEndCheck(pushNode, indents) { | ||
* @param {ASTNode[]} children - consequent child nodes of case node | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -182,7 +182,7 @@ function markCase(caseNode, children) { | ||
* @param {ASTNode} node - targeted node | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
function markChildren(node) { | ||
getChildren(node).forEach(function(childNode) { | ||
if (childNode.loc.start.line !== node.loc.start.line) { | ||
if (childNode.loc.start.line !== node.loc.start.line || node.type === "Program") { | ||
markCheck(childNode); | ||
@@ -197,3 +197,3 @@ } | ||
* @param {String} property - target node property containing child | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -291,3 +291,3 @@ function markAlternateBlockStatement(node, property) { | ||
* @param {ASTNode} node - node used only for reporting | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -300,2 +300,3 @@ function checkIndentations(node) { | ||
if (line.check) { | ||
if (actualIndentation !== expectedIndentation) { | ||
@@ -358,3 +359,3 @@ context.report(node, | ||
* @param {Number} actualIndentation - actual indentation at current line | ||
* @returns {void} (no description) | ||
* @returns {void} | ||
*/ | ||
@@ -361,0 +362,0 @@ function pushExpectedIndentations(line, actualIndentation) { |
@@ -17,15 +17,18 @@ /** | ||
for (i = 0, l = body.length; i < l; ++i) { | ||
e = body[i]; | ||
if (body) { | ||
for (i = 0, l = body.length; i < l; ++i) { | ||
e = body[i]; | ||
if ( | ||
e.type === "ExpressionStatement" && | ||
e.expression.type === "Literal" && | ||
typeof e.expression.value === "string" | ||
) { | ||
ds.push(e.expression); | ||
} else { | ||
break; | ||
if ( | ||
e.type === "ExpressionStatement" && | ||
e.expression.type === "Literal" && | ||
typeof e.expression.value === "string" | ||
) { | ||
ds.push(e.expression); | ||
} else { | ||
break; | ||
} | ||
} | ||
} | ||
return ds; | ||
@@ -32,0 +35,0 @@ } |
@@ -111,3 +111,3 @@ /** | ||
} else { | ||
isStrict = isStrictPragma(node.body.body[0]) || isParentStrict; | ||
isStrict = node.body.body && isStrictPragma(node.body.body[0]) || isParentStrict; | ||
} | ||
@@ -114,0 +114,0 @@ |
{ | ||
"name": "eslint", | ||
"version": "0.14.0", | ||
"version": "0.14.1", | ||
"author": "Nicholas C. Zakas <nicholas+npm@nczconsulting.com>", | ||
@@ -5,0 +5,0 @@ "description": "An AST-based pattern checker for JavaScript.", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11387
446631