Comparing version 6.3.0 to 6.3.1
@@ -317,6 +317,6 @@ 'use strict' | ||
if (typeof opts === 'string') { | ||
stream = buildSafeSonicBoom({ dest: opts }) | ||
stream = buildSafeSonicBoom({ dest: opts, sync: true }) | ||
opts = {} | ||
} else if (typeof stream === 'string') { | ||
stream = buildSafeSonicBoom({ dest: stream }) | ||
stream = buildSafeSonicBoom({ dest: stream, sync: true }) | ||
} else if (opts instanceof SonicBoom || opts.writable || opts._writableState) { | ||
@@ -345,3 +345,3 @@ stream = opts | ||
if (stream === process.stdout && stream.fd >= 0 && !hasBeenTampered(stream)) { | ||
stream = buildSafeSonicBoom({ fd: stream.fd }) | ||
stream = buildSafeSonicBoom({ fd: stream.fd, sync: true }) | ||
} | ||
@@ -348,0 +348,0 @@ if (prettyPrint) { |
{ | ||
"name": "pino", | ||
"version": "6.3.0", | ||
"version": "6.3.1", | ||
"description": "super fast, all natural json logger", | ||
@@ -5,0 +5,0 @@ "main": "pino.js", |
@@ -25,2 +25,17 @@ 'use strict' | ||
test('pino with no args log everything when calling process.exit(0)', async ({ isNot }) => { | ||
var actual = '' | ||
const child = execa(process.argv[0], [join(__dirname, 'fixtures', 'default-exit.js')]) | ||
child.stdout.pipe(writer((s, enc, cb) => { | ||
actual += s | ||
cb() | ||
})) | ||
await once(child, 'close') | ||
isNot(actual.match(/hello/), null) | ||
isNot(actual.match(/world/), null) | ||
}) | ||
test('sync false does not log everything when calling process.exit(0)', async ({ is }) => { | ||
@@ -27,0 +42,0 @@ var actual = '' |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
302612
84
7117
30