GT2/GT2-Android/node_modules/minipass/bench/lib/nullsink.js

13 lines
216 B
JavaScript

'use strict'
const EE = require('events').EventEmitter
module.exports = class NullSink extends EE {
write (data, encoding, next) {
if (next) next()
return true
}
end () {
this.emit('finish')
}
}