Commit 77f48dc0 authored by Julien Fontanet's avatar Julien Fontanet

chore(createWriteStream): coding style

parent fc877953
...@@ -15,8 +15,7 @@ module.exports = function createWriteStream(path, options, cb) { ...@@ -15,8 +15,7 @@ module.exports = function createWriteStream(path, options, cb) {
var createDisposition; var createDisposition;
var flags = options != null && options.flags; var flags = options != null && options.flags;
if (flags == null) { if (flags === 'r+') {
} else if (flags === 'r+') {
createDisposition = constants.FILE_OPEN; createDisposition = constants.FILE_OPEN;
} else if (flags === 'w' || flags === 'w+') { } else if (flags === 'w' || flags === 'w+') {
createDisposition = constants.FILE_OVERWRITE_IF; createDisposition = constants.FILE_OVERWRITE_IF;
...@@ -49,7 +48,7 @@ module.exports = function createWriteStream(path, options, cb) { ...@@ -49,7 +48,7 @@ module.exports = function createWriteStream(path, options, cb) {
Offset: offset.toBuffer(), Offset: offset.toBuffer(),
}, },
connection, connection,
function(err, result) { function(err) {
if (err != null) { if (err != null) {
return cb(err); return cb(err);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment