diff options
author | Ben Noordhuis <info@bnoordhuis.nl> | 2012-06-06 21:07:54 +0200 |
---|---|---|
committer | Ben Noordhuis <info@bnoordhuis.nl> | 2012-06-06 21:08:38 +0200 |
commit | c381662cac0e897b4bfdb2c31cd3117c5ecd2130 (patch) | |
tree | 975f34f66c29eec1fbfaa006e2116f402a6546ee | |
parent | b9c5eee7d9ad8d720c6f28dc78ab288c7b0e004c (diff) | |
download | node-c381662cac0e897b4bfdb2c31cd3117c5ecd2130.tar.gz |
fs: make fs.symlink() with no callback async
Fix a bug where fs.symlink('foo', 'bar') executed symlink(2) synchronously.
-rw-r--r-- | lib/fs.js | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -478,7 +478,7 @@ fs.readlinkSync = function(path) { fs.symlink = function(destination, path, type_, callback) { var type = (typeof(type_) == 'string' ? type_ : null); var callback_ = arguments[arguments.length - 1]; - callback = (typeof(callback_) == 'function' ? callback_ : null); + callback = (typeof(callback_) == 'function' ? callback_ : noop); if (isWindows && type === 'junction') { destination = pathModule._makeLong(destination); |