Skip to content

Commit

Permalink
add silent option to LogLevel (#4432)
Browse files Browse the repository at this point in the history
  • Loading branch information
Uzlopak committed Nov 21, 2022
1 parent 9c1be2a commit a8873ef
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions test/types/logger.test-d.ts
Expand Up @@ -183,6 +183,7 @@ expectDeprecated({} as FastifyLoggerInstance)
const childParent = fastify().log
// we test different option variant here
expectType<FastifyLoggerInstance>(childParent.child({}, { level: 'info' }))
expectType<FastifyLoggerInstance>(childParent.child({}, { level: 'silent' }))
expectType<FastifyLoggerInstance>(childParent.child({}, { redact: ['pass', 'pin'] }))
expectType<FastifyLoggerInstance>(childParent.child({}, { serializers: { key: () => {} } }))
expectType<FastifyLoggerInstance>(childParent.child({}, { level: 'info', redact: ['pass', 'pin'], serializers: { key: () => {} } }))
Expand Down
2 changes: 1 addition & 1 deletion types/logger.d.ts
Expand Up @@ -13,7 +13,7 @@ import pino from 'pino'
*/
export type FastifyLogFn = pino.LogFn

export type LogLevel = pino.Level
export type LogLevel = pino.LevelWithSilent

export type Bindings = pino.Bindings

Expand Down

0 comments on commit a8873ef

Please sign in to comment.