summaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/tar/node_modules/minipass/bench/lib/extend-through2.js
blob: 6a021084c42fbc51d480947f8c014244bf73c062 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
'use strict'
const through2 = require('through2')
module.exports = function (opt) {
  return opt.objectMode
    ? through2.obj(func)
    : through2(func)

  function func (data, enc, done) {
    this.push(data, enc)
    done()
  }
}