txlyre 2 年之前
父节点
当前提交
a72baed3ac
共有 1 个文件被更改,包括 5 次插入0 次删除
  1. 5 0
      commands.py

+ 5 - 0
commands.py

@@ -217,6 +217,11 @@ async def bday_handler(bot, event, command):
 
       return
 
+    if date >= datetime.now():
+      await event.reply('День рождения не может быть в будущем...')
+
+      return
+
     if await add_or_update_birthday(get_peer_id(event.peer_id), event.sender, date):
       await event.reply('День рождения успешно добавлен!!!')
     else: