Merge pull request #1002 from jessopb/changelogging
adds timestamp to logging
This commit is contained in:
commit
d84c964ae0
1 changed files with 7 additions and 7 deletions
|
@ -3,7 +3,7 @@ const logger = require('winston');
|
|||
const config = require('@config/loggerConfig');
|
||||
const { logLevel } = config;
|
||||
|
||||
function configureLogging () {
|
||||
function configureLogging() {
|
||||
logger.info('configuring winston logger...');
|
||||
if (!config) {
|
||||
return logger.warn('No logger config found');
|
||||
|
@ -14,12 +14,12 @@ function configureLogging () {
|
|||
// configure the winston logger
|
||||
logger.configure({
|
||||
transports: [
|
||||
new (logger.transports.Console)({
|
||||
level : logLevel || 'debug',
|
||||
timestamp : false,
|
||||
colorize : true,
|
||||
prettyPrint : true,
|
||||
handleExceptions : true,
|
||||
new logger.transports.Console({
|
||||
level: logLevel || 'debug',
|
||||
timestamp: true,
|
||||
colorize: true,
|
||||
prettyPrint: true,
|
||||
handleExceptions: true,
|
||||
humanReadableUnhandledException: true,
|
||||
}),
|
||||
],
|
||||
|
|
Loading…
Reference in a new issue