fstream
Advanced tools
Comparing version 1.0.9 to 1.0.10
@@ -6,2 +6,4 @@ module.exports = collect | ||
if (stream._paused) return stream.on('resume', collect.bind(null, stream)) | ||
stream._collected = true | ||
@@ -8,0 +10,0 @@ stream.pause() |
@@ -27,3 +27,2 @@ // A thing that emits "entry" events with Reader objects | ||
self.entries = null | ||
self._entries = [] | ||
self._index = -1 | ||
@@ -52,3 +51,2 @@ self._paused = false | ||
self.entries = entries | ||
self._entries = entries.slice() | ||
@@ -81,3 +79,3 @@ self.emit('entries', entries) | ||
self._index++ | ||
if (self._index >= self._entries.length) { | ||
if (self._index >= self.entries.length) { | ||
if (!self._ended) { | ||
@@ -91,10 +89,8 @@ self._ended = true | ||
// ok, handle this one, then. | ||
// save creating a proxy, by stat'ing the thing now. | ||
var nextEntry = self._entries[self._index] | ||
if (!nextEntry) return this._read() | ||
// ok, handle this one, then. | ||
var p = path.resolve(self._path, nextEntry) | ||
var p = path.resolve(self._path, self.entries[self._index]) | ||
assert(p !== self._path) | ||
assert(nextEntry) | ||
assert(self.entries[self._index]) | ||
@@ -101,0 +97,0 @@ // set this to prevent trying to _read() again in the stat time. |
@@ -5,3 +5,3 @@ { | ||
"description": "Advanced file system stream things", | ||
"version": "1.0.9", | ||
"version": "1.0.10", | ||
"repository": { | ||
@@ -8,0 +8,0 @@ "type": "git", |
Sorry, the diff of this file is not supported yet
63518
24
1919