Skip to content

Commit

Permalink
test: fix invalid variable name
Browse files Browse the repository at this point in the history
The variable `er` is not declared at all. So if EPERM error is ever
raised then the `er` will throw `ReferenceError` and the code will
break.

PR-URL: #3150
Reviewed-By: Brian White <[email protected]>
  • Loading branch information
thefourtheye committed Oct 1, 2015
1 parent 3f476ad commit 6be2a59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ function rimrafSync(p) {
if (e.code === 'ENOENT')
return;
if (e.code === 'EPERM')
return rmdirSync(p, er);
return rmdirSync(p, e);
if (e.code !== 'EISDIR')
throw e;
rmdirSync(p, e);
Expand Down

0 comments on commit 6be2a59

Please sign in to comment.