From 5719a7164c4710d8a9f9bad8fe0f0a582a600ae3 Mon Sep 17 00:00:00 2001 From: xxeol Date: Wed, 19 Jan 2022 00:11:41 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20failRoom=20=EC=A1=B0=ED=9A=8C?= =?UTF-8?q?=EC=8B=9C=20day=20!=3D0=20=EC=A1=B0=EA=B1=B4=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- functions/db/room.js | 1 + functions/scheduler/scheduler.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/functions/db/room.js b/functions/db/room.js index 7ba1674..fec3f0a 100644 --- a/functions/db/room.js +++ b/functions/db/room.js @@ -366,6 +366,7 @@ const getFailRecords = async (client) => { AND e.is_out = FALSE AND e.is_kicked = FALSE AND e.is_deleted = FALSE + AND r.day != 0 AND r.status IN ('NONE', 'CONSIDER') AND r.date = $1 GROUP BY e.room_id diff --git a/functions/scheduler/scheduler.js b/functions/scheduler/scheduler.js index 6e37e51..db7ce55 100644 --- a/functions/scheduler/scheduler.js +++ b/functions/scheduler/scheduler.js @@ -2,7 +2,7 @@ const schedule = require('node-schedule'); const funcs = require('./funcs.js'); -const job = schedule.scheduleJob('* 15 * * *', function() { +const job = schedule.scheduleJob('0 * * * *', function() { funcs.checkLife(); }); From 3341e53cd836050032492fa447ebf44e377f11a5 Mon Sep 17 00:00:00 2001 From: xxeol Date: Wed, 19 Jan 2022 00:12:11 +0900 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20scheduleJob=20=EC=8B=9C=EA=B0=84=20?= =?UTF-8?q?=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- functions/scheduler/scheduler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/scheduler/scheduler.js b/functions/scheduler/scheduler.js index db7ce55..6e37e51 100644 --- a/functions/scheduler/scheduler.js +++ b/functions/scheduler/scheduler.js @@ -2,7 +2,7 @@ const schedule = require('node-schedule'); const funcs = require('./funcs.js'); -const job = schedule.scheduleJob('0 * * * *', function() { +const job = schedule.scheduleJob('* 15 * * *', function() { funcs.checkLife(); });