Software: Apache. PHP/8.1.30 uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root) Safe-mode: OFF (not secure) /home/picotech/domains/wa.picotech.app/public_html/node_modules/pino-abstract-transport/ drwxr-xr-x |
Viewing file: Select action/file-type: 'use strict' const metadata = Symbol.for('pino.metadata') const split = require('split2') const duplexify = require('duplexify') module.exports = function build (fn, opts = {}) { const parseLines = opts.parse === 'lines' const parseLine = typeof opts.parseLine === 'function' ? opts.parseLine : JSON.parse const close = opts.close || defaultClose const stream = split(function (line) { let value try { value = parseLine(line) } catch (error) { this.emit('unknown', line, error) return } if (value === null) { this.emit('unknown', line, 'Null value ignored') return } if (typeof value !== 'object') { value = { data: value, time: Date.now() } } if (stream[metadata]) { stream.lastTime = value.time stream.lastLevel = value.level stream.lastObj = value } if (parseLines) { return line } return value }, { autoDestroy: true }) stream._destroy = function (err, cb) { const promise = close(err, cb) if (promise && typeof promise.then === 'function') { promise.then(cb, cb) } } if (opts.metadata !== false) { stream[metadata] = true stream.lastTime = 0 stream.lastLevel = 0 stream.lastObj = null } let res = fn(stream) if (res && typeof res.catch === 'function') { res.catch((err) => { stream.destroy(err) }) // set it to null to not retain a reference to the promise res = null } else if (opts.enablePipelining && res) { return duplexify(stream, res, { objectMode: true }) } return stream } function defaultClose (err, cb) { process.nextTick(cb, err) } |
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0038 ]-- |