-const logger = winston.createLogger({
- level: Configuration.getLogLevel(),
- format: winston.format.combine(winston.format.splat(), winston.format[Configuration.getLogFormat()]()),
- transports: [
- //
- // - Write to all logs with level `info` and below to `combined.log`
- // - Write all logs error (and below) to `error.log`.
- //
- new winston.transports.DailyRotateFile({ filename: Utils.insertAt(Configuration.getLogErrorFile(), '-%DATE%', Configuration.getLogErrorFile().indexOf('.log')), level: 'error', maxFiles: maxLogFiles }),
- new winston.transports.DailyRotateFile({ filename: Utils.insertAt(Configuration.getLogFile(), '-%DATE%', Configuration.getLogFile().indexOf('.log')), maxFiles: maxLogFiles }),
- ],
+const logger: Logger = createLogger({
+ level: Configuration.getLogLevel().toLowerCase(),
+ format: format.combine(format.splat(), format[Configuration.getLogFormat()]()),
+ transports: transports,