sync mode on
This commit is contained in:
1 parent
1818932244
commit
1174b328e5
415 files changed
+44294
-1182
No files matched your search
+12
@@ -0,0 +1,12 @@
|
||||
'use strict'
|
||||
|
||||
const pino = require('./pino')
|
||||
const { once } = require('node:events')
|
||||
|
||||
module.exports = async function (opts = {}) {
|
||||
const destOpts = Object.assign({}, opts, { dest: opts.destination || 1, sync: false })
|
||||
delete destOpts.destination
|
||||
const destination = pino.destination(destOpts)
|
||||
await once(destination, 'ready')
|
||||
return destination
|
||||
}
|
||||
Reference in new issue
Block a user