Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
fix(cli/main): corrects incorrect callback for fs.writeFile op
Browse files Browse the repository at this point in the history
corrects fs.writeFile callback function and error check

fixes #31
edm00se committed Oct 16, 2018
1 parent bdfbbd1 commit 21a0f0f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/cli/main.js
Original file line number Diff line number Diff line change
@@ -51,7 +51,11 @@ module.exports = function() {
}
}
if (foundMatch) {
fs.writeFile(curVal, data, 'utf-8', err);
fs.writeFile(curVal, data, 'utf-8', function(err) {
if (writeErr) {
console.log(writeErr);
}
});
}
}
});

0 comments on commit 21a0f0f

Please sign in to comment.