Skip to content

Commit

Permalink
Fix failBuild flag to only be issued when there are lint errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
kratiahuja committed Mar 7, 2016
1 parent 9f1b424 commit 04ce436
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ TSLint.prototype.build = function () {
} else {
// throw in stdout
console.log(outputLog);
if (self.options.failBuild) {
if (self.options.failBuild && self.failureCount > 0) {
throw new Error('Build failed due to lint errors!');
}
}
Expand Down

0 comments on commit 04ce436

Please sign in to comment.