From 0bc340081fefcaead193a046a804af8eca683787 Mon Sep 17 00:00:00 2001 From: Moshe <62907797+moshe-coh@users.noreply.github.com> Date: Fri, 6 May 2022 23:08:23 +0300 Subject: [PATCH] Fix wrong enum usage (#988) --- pyrogram/types/user_and_chats/chat_event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyrogram/types/user_and_chats/chat_event.py b/pyrogram/types/user_and_chats/chat_event.py index a5292c64..88ff42f3 100644 --- a/pyrogram/types/user_and_chats/chat_event.py +++ b/pyrogram/types/user_and_chats/chat_event.py @@ -369,7 +369,7 @@ class ChatEvent(Object): elif isinstance(action, raw.types.ChannelAdminLogEventActionParticipantToggleAdmin): old_administrator_privileges = types.ChatMember._parse(client, action.prev_participant, users, chats) new_administrator_privileges = types.ChatMember._parse(client, action.new_participant, users, chats) - action = enums.ChatEventAction.ADMIN_RIGHTS_CHANGED + action = enums.ChatEventAction.ADMINISTRATOR_PRIVILEGES_CHANGED elif isinstance(action, raw.types.ChannelAdminLogEventActionParticipantToggleBan): old_member_permissions = types.ChatMember._parse(client, action.prev_participant, users, chats)