aboutsummaryrefslogtreecommitdiff
path: root/docs/ext
diff options
context:
space:
mode:
authorVexs <[email protected]>2019-04-10 02:31:55 -0500
committerRapptz <[email protected]>2019-04-20 16:45:37 -0400
commitbb3ebc0ebc26b1275364388f13b85f204917a55e (patch)
tree2ab4074479b1dd3474542b67f2a346f48470e98c /docs/ext
parentMake Message.ack an actual coroutine function. (diff)
downloaddiscord.py-bb3ebc0ebc26b1275364388f13b85f204917a55e.tar.xz
discord.py-bb3ebc0ebc26b1275364388f13b85f204917a55e.zip
[commands] Add custom exception classes for built-in checks
Added: * MissingRole * BotMissingRole * MissingAnyRole * BotMissingAnyRole
Diffstat (limited to 'docs/ext')
-rw-r--r--docs/ext/commands/api.rst24
1 files changed, 24 insertions, 0 deletions
diff --git a/docs/ext/commands/api.rst b/docs/ext/commands/api.rst
index 166fdb1d..3400efe0 100644
--- a/docs/ext/commands/api.rst
+++ b/docs/ext/commands/api.rst
@@ -255,6 +255,9 @@ Exceptions
.. autoexception:: discord.ext.commands.BadUnionArgument
:members:
+.. autoexception:: discord.ext.commands.PrivateMessageOnly
+ :members:
+
.. autoexception:: discord.ext.commands.NoPrivateMessage
:members:
@@ -288,6 +291,21 @@ Exceptions
.. autoexception:: discord.ext.commands.BotMissingPermissions
:members:
+.. autoexception:: discord.ext.commands.MissingRole
+ :members:
+
+.. autoexception:: discord.ext.commands.BotMissingRole
+ :members:
+
+.. autoexception:: discord.ext.commands.MissingAnyRole
+ :members:
+
+.. autoexception:: discord.ext.commands.BotMissingAnyRole
+ :members:
+
+.. autoexception:: discord.ext.commands.NSFWChannelRequired
+ :members:
+
.. autoexception:: discord.ext.commands.ExtensionError
:members:
@@ -326,10 +344,16 @@ Exception Hierarchy
- :exc:`~.commands.ExpectedClosingQuoteError`
- :exc:`~.commands.CommandNotFound`
- :exc:`~.commands.CheckFailure`
+ - :exc:`~.commands.PrivateMessageOnly`
- :exc:`~.commands.NoPrivateMessage`
- :exc:`~.commands.NotOwner`
- :exc:`~.commands.MissingPermissions`
- :exc:`~.commands.BotMissingPermissions`
+ - :exc:`~.commands.MissingRole`
+ - :exc:`~.commands.BotMissingRole`
+ - :exc:`~.commands.MissingAnyRole`
+ - :exc:`~.commands.BotMissingAnyRole`
+ - :exc:`~.commands.NSFWChannelRequired`
- :exc:`~.commands.DisabledCommand`
- :exc:`~.commands.CommandInvokeError`
- :exc:`~.commands.CommandOnCooldown`