diff --git a/backend/Logger.ts b/backend/Logger.ts index ac64ab90..c29546d1 100644 --- a/backend/Logger.ts +++ b/backend/Logger.ts @@ -10,7 +10,7 @@ declare module 'winston' { export const winstonSettings = { transports: [ new winston.transports.Console({ - level: 'silly', + level: process.env.NODE_ENV == "production" ? "info" : 'silly', handleExceptions: true, json: false, colorize: true, diff --git a/backend/model/memory/UserManager.ts b/backend/model/memory/UserManager.ts index f179e9d7..a25ed630 100644 --- a/backend/model/memory/UserManager.ts +++ b/backend/model/memory/UserManager.ts @@ -56,8 +56,6 @@ export class UserManager implements IUserManager { delete filter.password; const users = (await this.db.get("users")).slice(); let i = users.length; - console.log("filer", filter); - console.log(users); while (i--) { if (pass && !(PasswordHelper.comparePassword(pass, users[i].password))) { users.splice(i, 1); diff --git a/backend/server.ts b/backend/server.ts index 41ba91c5..771ae1ac 100644 --- a/backend/server.ts +++ b/backend/server.ts @@ -25,7 +25,7 @@ export class Server { private server: any; constructor() { - if (process.env.DEBUG) { + if (!(process.env.NODE_ENV == "production")) { Logger.debug(LOG_TAG, "Running in DEBUG mode"); } this.init();