Fixed lock all

Signed-off-by: Yasir Aris M <git@yasirdev.my.id>
This commit is contained in:
Yasir Aris M 2023-10-28 21:22:22 +07:00 committed by GitHub
parent 0824a476b3
commit 3e3cca2750
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -165,7 +165,7 @@ async def locks_func(_, message):
await tg_lock(message, permissions, data[parameter], state == "lock")
elif parameter == "all" and state == "lock":
try:
await app.set_chat_permissions(chat_id, ChatPermissions(all_perms=True))
await app.set_chat_permissions(chat_id, ChatPermissions(all_perms=False))
await message.reply_text(f"Locked Everything in {message.chat.title}")
except ChatAdminRequired:
await message.reply_msg(