Comparing version 1.7.1 to 1.7.2
@@ -8,3 +8,3 @@ /** | ||
module.exports = function(config, instance) { | ||
instance._maxErrors = config.maxErrors; | ||
instance._maxErrors = Number(config.maxErrors); | ||
@@ -11,0 +11,0 @@ Object.defineProperty(config, 'maxErrors', { |
@@ -148,12 +148,9 @@ var assert = require('assert'); | ||
function getBreakIndents(caseNode, children) { | ||
var breakNode; | ||
if (_this._breakIndents === null) { | ||
children.some(function(node) { | ||
if (node.type === 'BreakStatement') { | ||
breakNode = node; | ||
if (node.type === 'BreakStatement' || node.type === 'ReturnStatement') { | ||
_this._breakIndents = (caseNode.loc.start.column === node.loc.start.column) ? 1 : 0; | ||
return true; | ||
} | ||
}); | ||
_this._breakIndents = (caseNode.loc.start.column === breakNode.loc.start.column) ? 1 : 0; | ||
} | ||
@@ -160,0 +157,0 @@ |
@@ -290,3 +290,3 @@ var defaultEsprima = require('esprima'); | ||
if (this._maxErrors !== undefined) { | ||
if (!isNaN(this._maxErrors)) { | ||
if (!this._maxErrorsExceeded) { | ||
@@ -293,0 +293,0 @@ this._maxErrorsExceeded = this._errorsFound + errors.getErrorCount() > this._maxErrors; |
@@ -5,3 +5,3 @@ { | ||
"name": "jscs", | ||
"version": "1.7.1", | ||
"version": "1.7.2", | ||
"main": "lib/checker", | ||
@@ -8,0 +8,0 @@ "homepage": "https://github.com/jscs-dev/node-jscs", |
@@ -98,3 +98,3 @@ # node-jscs | ||
### '--esnext' | ||
### `--esnext` | ||
Attempts to parse your code as ES6 using the harmony version of the esprima parser. Please note that this is currently experimental, and will improve over time. | ||
@@ -105,3 +105,3 @@ | ||
### '--max-errors' | ||
### `--max-errors` | ||
Set the maximum number of errors to report | ||
@@ -108,0 +108,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
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
875431
21451