Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

check if queued method is a function

  • Loading branch information...
commit 20a620b3a272abc385c397846aa6d727f10cbbf8 1 parent 0ee1a50
@fent authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/index.js
View
4 lib/index.js
@@ -50,7 +50,9 @@ var Streamify = module.exports = function Streamify(options) {
// queue method calls until real stream is ready
Object.keys(options.superCtor.prototype).forEach(function(key) {
- o.queueMethod(key);
+ if (typeof options.superCtor.prototype[key] === 'function') {
+ o.queueMethod(key);
+ }
});
// queue more methods from the stream spec
Please sign in to comment.
Something went wrong with that request. Please try again.