diff --git a/logging/WinstonLogger.ts b/logging/WinstonLogger.ts index a81f1edc4cc3f429ba1d27135cc890150014aea3..7c991d89e6486a6758834432b0fc9c9634908822 100644 --- a/logging/WinstonLogger.ts +++ b/logging/WinstonLogger.ts @@ -25,7 +25,7 @@ const format = winston.format.combine(winston.format.timestamp({ format: 'YYYY-M level: info.level.toUpperCase() }))(), SharedConfig.production ? winston.format.uncolorize() : winston.format.colorize({ all: true }), winston.format.prettyPrint(), winston.format.errors({ stack: true }), winston.format.align(), winston.format.printf(info => { const metadata = info.metadata ? `\n${ JSON.stringify(info.metadata) }` : ''; - const stack = info.stack ? `\n${ info.stack }` : ''; + const stack = info.stack ? `\n${ JSON.stringify(info.stack, undefined, 4) }` : ''; return `[${ info.timestamp }] (${ process.pid }) ${ info.level } ${ info.message } ${ metadata } ${ stack } `; }));