Update Permissions.stage_moderator

This commit is contained in:
Stocker 2022-03-15 23:33:11 -04:00 committed by GitHub
parent 2d28d7b765
commit fd5dea4e34
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 3 deletions

View File

@ -231,12 +231,19 @@ class Permissions(BaseFlags):
@classmethod
def stage_moderator(cls) -> Self:
"""A factory method that creates a :class:`Permissions` with all
"Stage Moderator" permissions from the official Discord UI set to ``True``.
"""A factory method that creates a :class:`Permissions` with all permissions
for stage moderators set to ``True``. These permissions are currently:
- :attr:`manage_channels`
- :attr:`mute_members`
- :attr:`move_members`
.. versionadded:: 1.7
.. versionchanged:: 2.0
Added :attr:`manage_channels` permission and removed :attr:`request_to_speak` permission.
"""
return cls(0b100000001010000000000000000000000)
return cls(0b1010000000000000000010000)
@classmethod
def advanced(cls) -> Self:

View File

@ -1156,6 +1156,8 @@ The following changes have been made:
- :meth:`Message.edit` now merges object passed in ``allowed_mentions`` parameter with :attr:`Client.allowed_mentions`.
If the parameter isn't provided, the defaults given by :attr:`Client.allowed_mentions` are used instead.
- :meth:`Permissions.stage_moderator` now includes the :attr:`Permissions.manage_channels` permission and the :attr:`Permissions.request_to_speak` permission is no longer included.
.. _migrating_2_0_commands:
Command Extension Changes