Fixed changing models. Changed cooldown for changing models to 30m

This commit is contained in:
seel2304
2023-05-03 17:09:25 +00:00
parent 2dda780d3f
commit 75f6404e94
2 changed files with 6 additions and 4 deletions

View File

@@ -1,5 +1,5 @@
from aiogram import types
from bot.db import db, DBTables
from bot.db import db, DBTables, decrypt
from bot.utils.cooldown import throttle
from bot.keyboards.set_model import get_set_model_keyboard
from bot.modules.api.models import get_models
@@ -7,7 +7,7 @@ from bot.utils.errorable_command import wrap_exception
@wrap_exception()
@throttle(cooldown=60*60, admin_ids=db[DBTables.config].get('admins'), by_id=False)
@throttle(cooldown=30*60, admin_ids=db[DBTables.config].get('admins'), by_id=False)
async def set_model_command(message: types.Message):
models = await get_models()
if models is not None and len(models) > 0: