2.2 Мелкие улучшения и аннотации файлы
This commit is contained in:
@@ -9,7 +9,7 @@ from SQLite3 import status_user
|
||||
__all__ = ("ban_cmd",)
|
||||
|
||||
# Функция блокировки пользователя
|
||||
async def ban_user(message: types.Message, *args, **kwargs):
|
||||
async def ban_user(message: types.Message, *args, **kwargs) -> None:
|
||||
status = await status_user(message)
|
||||
if status not in ('Пользователь', 'Забаннен'):
|
||||
# Проверка, что команда вызвана с упоминанием пользователя
|
||||
|
||||
@@ -24,7 +24,7 @@ secret_keywords = ["setcommands", "setcommand", "ыуесщььфтвы", "ыу
|
||||
@router.message(
|
||||
#F.from_user.id.func(lambda user_id: str(user_id) in DataID.important.keys()),
|
||||
F.text.lower().in_(secret_keywords))
|
||||
async def set_commands():
|
||||
async def set_commands() -> None:
|
||||
bot_commands = [
|
||||
types.BotCommand(command=start_cmd.name, description=start_cmd.description),
|
||||
types.BotCommand(command=help_cmd.name, description=help_cmd.description),
|
||||
|
||||
Reference in New Issue
Block a user