MCPcopy
hub / github.com/fastify/fastify / customRouteChildLogger

Function customRouteChildLogger

test/route.5.test.js:11–17  ·  view source on GitHub ↗
(logger, bindings, opts, req)

Source from the content-addressed store, hash-verified

9 const fastify = Fastify()
10
11 const customRouteChildLogger = (logger, bindings, opts, req) => {
12 const child = logger.child(bindings, opts)
13 child.customLog = function (message) {
14 t.assert.strictEqual(message, 'custom')
15 }
16 return child
17 }
18
19 fastify.route({
20 method: 'GET',

Callers

nothing calls this directly

Calls 1

childMethod · 0.65

Tested by

no test coverage detected