Skip to content

Commit

Permalink
Add forum filter
Browse files Browse the repository at this point in the history
  • Loading branch information
KurimuzonAkuma committed Dec 15, 2023
1 parent 5f43892 commit 8e201b9
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions pyrogram/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,17 @@ async def channel_filter(_, __, m: Message):
"""Filter messages sent in channels."""


# endregion

# region forum_filter
async def forum_filter(_, __, m: Message):
return bool(m.chat and m.chat.is_forum)


forum = create(forum_filter)
"""Filter messages sent in forums."""


# endregion

# region new_chat_members_filter
Expand Down

0 comments on commit 8e201b9

Please sign in to comment.