mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 23:27:26 +01:00
add timestamps to logs
This commit is contained in:
@@ -16,6 +16,7 @@ const logger = new winston.Logger();
|
||||
if (IS_PROD) {
|
||||
if (ENABLE_LOGS_IN_PROD) {
|
||||
logger.add(winston.transports.Console, {
|
||||
timestamp: true,
|
||||
colorize: false,
|
||||
prettyPrint: false,
|
||||
});
|
||||
@@ -23,6 +24,7 @@ if (IS_PROD) {
|
||||
} else if (!IS_TEST || IS_TEST && ENABLE_LOGS_IN_TEST) { // Do not log anything when testing unless specified
|
||||
logger
|
||||
.add(winston.transports.Console, {
|
||||
timestamp: true,
|
||||
colorize: true,
|
||||
prettyPrint: true,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user