Skip to content

Commit

Permalink
tools: fix error detection (#914)
Browse files Browse the repository at this point in the history
The `ChildProces` object `result` does not have an `error` property. We
should use `stderr` instead.
  • Loading branch information
RaisinTen authored Feb 23, 2021
1 parent 458d895 commit 12c548b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/clang-format.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ function main(args) {
...filesToCheck
], { encoding: 'utf-8' });

if (result.error) {
console.error('Error running git-clang-format:', result.error);
if (result.stderr) {
console.error('Error running git-clang-format:', result.stderr);
return 2;
}

Expand Down

0 comments on commit 12c548b

Please sign in to comment.