14 lines
333 B
JavaScript
14 lines
333 B
JavaScript
|
|
const Stream = require('stream');
|
||
|
|
const util = require('util');
|
||
|
|
function NoopStream() {
|
||
|
|
if (!(this instanceof NoopStream)) {
|
||
|
|
return new NoopStream();
|
||
|
|
}
|
||
|
|
Stream.Transform.call(this);
|
||
|
|
}
|
||
|
|
|
||
|
|
util.inherits(NoopStream, Stream.Transform);
|
||
|
|
|
||
|
|
NoopStream.prototype._transform = function(d, e, cb) { cb() ;};
|
||
|
|
|
||
|
|
module.exports = NoopStream;
|