mirror of https://github.com/lukechilds/node.git
Browse Source
This handles the fact that stream.Writable inherits from the Stream class, meaning that it has the legacy pipe() method. Override that with a pipe() method that emits an error. Ensure that Duplex streams ARE still pipe()able, however. Since the 'readable' flag on streams is sometimes temporary, it's probably better not to put too much weight on that. But if something is an instanceof Writable, rather than of Readable or Duplex, then it's safe to say that reading from it is the wrong thing to do. Fix #3647v0.9.11-release
2 changed files with 31 additions and 0 deletions
Loading…
Reference in new issue