killallmembers v1.02 修复频繁edit导致的报错

This commit is contained in:
b miao 2021-03-06 21:20:07 +08:00
parent 812c83d0eb
commit 3e99688509
2 changed files with 3 additions and 2 deletions

View File

@ -35,7 +35,8 @@ async def killallmembers(context):
try:
await bot.edit_permissions(context.chat_id, user_id, view_messages=False)
i += 1
await context.edit(f'进度:{i}/{len(users_wo_admins)}')
if i % 10 == 0:
await context.edit(f'进度:{i}/{len(users_wo_admins)}')
except:
await context.edit('发生错误')
await sleep(10)

View File

@ -292,7 +292,7 @@
},
{
"name": "killallmembers",
"version": "1.01",
"version": "1.02",
"section": "chat",
"maintainer": "Pentacene",
"size": "idk",