From 3c3c2ee3c52cabfc111520dc1e39e639b975ceb0 Mon Sep 17 00:00:00 2001 From: Daniel Bulant Date: Fri, 26 Nov 2021 18:38:47 +0100 Subject: [PATCH] I hate sobota --- commands/ssps/rozvrh.js | 1 + 1 file changed, 1 insertion(+) diff --git a/commands/ssps/rozvrh.js b/commands/ssps/rozvrh.js index 92fb964..0fa5e81 100644 --- a/commands/ssps/rozvrh.js +++ b/commands/ssps/rozvrh.js @@ -47,6 +47,7 @@ module.exports = class rozvrh extends commando.Command { if(date.weekday === 0 || date.weekday === 7) { date = date.plus({ days: date.weekday === 0 ? 2 : 1 }); } + if(date.weekday > 5) date = date.plus({ days: 8 - date.weekday}); const schedule = await Timetable.findAll({ where: { day: date.weekday - 1,