diff options
Diffstat (limited to 'handlers/gen.py')
| -rw-r--r-- | handlers/gen.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/handlers/gen.py b/handlers/gen.py index 43301c5..b618fec 100644 --- a/handlers/gen.py +++ b/handlers/gen.py | |||
| @@ -43,7 +43,7 @@ async def изменить_шанс_срания(msg: t.Message): | |||
| 43 | try: | 43 | try: |
| 44 | chance = int(msg.get_args().split()[0]) | 44 | chance = int(msg.get_args().split()[0]) |
| 45 | if 0 <= chance <= 100: | 45 | if 0 <= chance <= 100: |
| 46 | config.chances[msg.chat.id] = chance | 46 | config.chances[str(msg.chat.id)] = chance |
| 47 | config.save() | 47 | config.save() |
| 48 | else: | 48 | else: |
| 49 | raise RuntimeError() | 49 | raise RuntimeError() |
| @@ -54,7 +54,7 @@ async def изменить_шанс_срания(msg: t.Message): | |||
| 54 | "Я хз что не так, но я знаю что ты дебил \n /chance <ЧИСЛО ОТ 0 ДО 100>" | 54 | "Я хз что не так, но я знаю что ты дебил \n /chance <ЧИСЛО ОТ 0 ДО 100>" |
| 55 | ) | 55 | ) |
| 56 | else: | 56 | else: |
| 57 | await msg.answer(f"Я сру с шансом в: {config.chances.get(msg.chat.id, 10)}%") | 57 | await msg.answer(f"Я сру с шансом в: {config.chances.get(str(msg.chat.id), 10)}%") |
| 58 | 58 | ||
| 59 | 59 | ||
| 60 | @dp.message_handler(f.message.chance, content_types=[t.ContentType.ANY]) | 60 | @dp.message_handler(f.message.chance, content_types=[t.ContentType.ANY]) |
