Skip to content

Commit

Permalink
Don't leave a dir artifact where a file might go (#169)
Browse files Browse the repository at this point in the history
Co-authored-by: Alec Reynolds <[email protected]>
Co-authored-by: Mike Pirog <[email protected]>
  • Loading branch information
3 people committed Oct 10, 2024
1 parent 6790b63 commit 91d12bb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions utils/move-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ module.exports = (src, dest = os.tmpdir()) => {

// Catch this so we can try to repair
if (code !== 'EISDIR' || syscall !== 'open' || !!fs.mkdirSync(f, {recursive: true})) {
fs.removeSync(f);
throw new Error(error);
}

Expand Down

0 comments on commit 91d12bb

Please sign in to comment.