Skip to content

Commit

Permalink
Fix wrong error summary and exit code reported
Browse files Browse the repository at this point in the history
fixes #53
  • Loading branch information
robatwilliams committed Jan 6, 2023
1 parent 3c92599 commit b9244ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/check-es-compat/bin/cli.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,5 @@ async function execute(files) {
const formatter = await eslint.loadFormatter();
console.log(formatter.format(results));

return { hasErrors: results.errorCount > 0 };
return { hasErrors: results.some((result) => result.errorCount > 0) };
}

0 comments on commit b9244ae

Please sign in to comment.