hedgedoc/lib/logger.js

24 lines
433 B
JavaScript
Raw Normal View History

'use strict'
const winston = require('winston')
2015-06-01 06:04:25 -04:00
class Logger extends winston.Logger {
// Implement stream.writable.write interface
write (chunk) {
this.info(chunk)
}
}
module.exports = new Logger({
transports: [
new winston.transports.Console({
level: 'debug',
handleExceptions: true,
json: false,
colorize: false,
timestamp: true
})
],
emitErrs: true,
exitOnError: false
})