Comparing version 0.1.20 to 0.1.21
@@ -39,2 +39,3 @@ module.exports = FileWriter | ||
me._stream.on("open", function (fd) { | ||
// console.error("FW open", me._buffer, me._path) | ||
me.ready = true | ||
@@ -46,2 +47,4 @@ me._buffer.forEach(function (c) { | ||
me.emit("ready") | ||
// give this a kick just in case it needs it. | ||
me.emit("drain") | ||
}) | ||
@@ -63,2 +66,4 @@ | ||
if (!me.ready) { | ||
if (!Buffer.isBuffer(c) && typeof c !== 'string') | ||
throw new Error('invalid write data') | ||
me._buffer.push(c) | ||
@@ -65,0 +70,0 @@ return false |
@@ -74,3 +74,3 @@ // A writer for when we don't know what kind of thing | ||
// console.error("~~ ~~ proxy buffered call", c[0], c[1]) | ||
proxy[c[0]].call(proxy, c[1]) | ||
proxy[c[0]].apply(proxy, c[1]) | ||
}) | ||
@@ -106,3 +106,3 @@ me._buffer.length = 0 | ||
if (!this._proxy) { | ||
this._buffer.push(["end", c]) | ||
this._buffer.push(["end", [c]]) | ||
return false | ||
@@ -109,0 +109,0 @@ } |
@@ -5,3 +5,3 @@ { | ||
"description": "Advanced file system stream things", | ||
"version": "0.1.20", | ||
"version": "0.1.21", | ||
"repository": { | ||
@@ -8,0 +8,0 @@ "type": "git", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
63570
1867