wikijs-fork/libs/winston.js

18 lines
309 B
JavaScript
Raw Normal View History

"use strict";
var winston = require('winston');
module.exports = (isDebug) => {
2016-10-17 23:52:04 +00:00
winston.remove(winston.transports.Console);
winston.add(winston.transports.Console, {
level: (isDebug) ? 'info' : 'warn',
prettyPrint: true,
colorize: true,
silent: false,
timestamp: true
});
return winston;
};