Disable les

This commit is contained in:
Stijn De Clercq 2021-04-05 15:27:58 +02:00
parent c1169b4496
commit f655748025
4 changed files with 32 additions and 15 deletions

View file

@ -23,8 +23,15 @@ def createEmbed(day, dayDatetime, semester, year, schedule):
# Create a date object to check the current week
startDate = 1612224000
currentTime = dayDatetime.timestamp()
week = clamp(timeFormatters.timeIn(currentTime - startDate, "weeks")[0], 1, 13)
# Compensate for easter holidays
# Sorry but I don't have time to make a clean solution for this rn
# this will have to do
if currentTime > 1617377400:
week -= 2
title, week = getTitle(day, dayDatetime, week)
# Add all courses & their corresponding times + locations of today