From 1b785f5acc299080363f5ebb32a0ff2e8c27f2ce Mon Sep 17 00:00:00 2001 From: Redume Date: Sun, 11 Aug 2024 17:21:20 +0300 Subject: [PATCH] =?UTF-8?q?=D0=95=D1=81=D0=BB=D0=B8=20=D0=B2=20=D0=BA?= =?UTF-8?q?=D0=BE=D0=BD=D1=84=D0=B8=D0=B3=D0=B5=20=D0=B2=D0=BA=D0=BB=D1=8E?= =?UTF-8?q?=D1=87=D0=B5=D0=BD,=20=D1=82=D0=BE=20=D0=B1=D1=83=D0=B4=D0=B5?= =?UTF-8?q?=D1=82=20=D0=B2=D1=8B=D0=B2=D0=BE=D0=B4=D0=B8=D1=82=D1=81=D1=8F?= =?UTF-8?q?=20=D0=B4=D0=B5=D0=B1=D0=B0=D0=B3=20=D0=B8=D0=BD=D1=84=D0=B0=20?= =?UTF-8?q?=D0=B2=20=D0=BA=D0=BE=D0=BD=D1=81=D0=BE=D0=BB=D1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logger/main.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/logger/main.js b/logger/main.js index 3a12f40..f2c2219 100644 --- a/logger/main.js +++ b/logger/main.js @@ -1,6 +1,9 @@ const pino = require('pino'); const pretty = require('pino-pretty'); +const config = require('../config/main.js')(); -const logger = pino(pretty()); +const logger = pino({ + level: config['server']['debug'] ? 'debug' : 'info', + }, pretty()); module.exports = logger; \ No newline at end of file