Add support for on_audit_log_entry_create event

This commit is contained in:
Rapptz
2023-01-12 18:16:36 -05:00
parent 24495e5505
commit 2869d8000d
5 changed files with 65 additions and 6 deletions

View File

@ -777,18 +777,28 @@ class Intents(BaseFlags):
return 1 << 1
@flag_value
def bans(self):
""":class:`bool`: Whether guild ban related events are enabled.
def moderation(self):
""":class:`bool`: Whether guild moderation related events are enabled.
This corresponds to the following events:
- :func:`on_member_ban`
- :func:`on_member_unban`
- :func:`on_audit_log_entry_create`
This does not correspond to any attributes or classes in the library in terms of cache.
"""
return 1 << 2
@alias_flag_value
def bans(self):
""":class:`bool`: An alias of :attr:`moderation`.
.. versionchanged:: 2.2
Changed to an alias.
"""
return 1 << 2
@flag_value
def emojis(self):
""":class:`bool`: Alias of :attr:`.emojis_and_stickers`.