diff --git a/bot/commands/advent.py b/bot/commands/advent.py index 30c593e..189c1cc 100644 --- a/bot/commands/advent.py +++ b/bot/commands/advent.py @@ -125,8 +125,8 @@ class AdventsHandler(BaseHandler): reply_markup = InlineKeyboardMarkup(keyboard) - #if tuer_nummer <= int(date.today().strftime("%d")): - if (tuer_nummer <= int(date.today().strftime("%d"))) and (int(date.today().strftime("%m"))==12): + datum_tuer_heute = date(2023, 12, tuer_nummer) + if (date.today() - datum_tuer_heute).days >= 0: await update.message.reply_document(document=GIF_LOCATION/ f"gif{tuer_nummer}.mp4", caption=f"Türchen für den {tuer_nummer}. Dezember: \n" + self.tuerchen_texte[tuerchen], reply_markup=reply_markup) else: await update.message.reply_sticker(sticker=STICKER_LOCATION/"stickerangry.tgs")