From 25f23ec11366af17d35b696752e14a2e88983f0f Mon Sep 17 00:00:00 2001 From: webtax-gh <72332327+webtax-gh@users.noreply.github.com> Date: Wed, 18 Nov 2020 17:49:39 -0800 Subject: [PATCH] Properly document that categories throw 404's on create_invite. --- discord/abc.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/discord/abc.py b/discord/abc.py index 9dffb8d2e..91da74dfa 100644 --- a/discord/abc.py +++ b/discord/abc.py @@ -710,7 +710,7 @@ class GuildChannel: async def create_invite(self, *, reason=None, **fields): """|coro| - Creates an instant invite. + Creates an instant invite from a text or voice channel. You must have the :attr:`~Permissions.create_instant_invite` permission to do this. @@ -738,6 +738,9 @@ class GuildChannel: ~discord.HTTPException Invite creation failed. + ~discord.NotFound + The channel that was passed is a category or an invalid channel. + Returns -------- :class:`~discord.Invite`