Skip to content

Commit

Permalink
Fix typo in fs.writeFile
Browse files Browse the repository at this point in the history
  • Loading branch information
creationix authored and ry committed Feb 21, 2010
1 parent ea4956f commit 68af59e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/node.js
Expand Up @@ -508,7 +508,7 @@ var fsModule = createInternalModule("fs", function (exports) {
if (callback) callback(writeErr);
});
} else {
if (written === _data.length) {
if (written === data.length) {
exports.close(fd, callback);
} else {
writeAll(fd, data.slice(written), encoding, callback);
Expand Down

0 comments on commit 68af59e

Please sign in to comment.