aboutsummaryrefslogtreecommitdiff
path: root/discord/ext/commands/context.py
diff options
context:
space:
mode:
authorRapptz <[email protected]>2019-02-23 04:10:10 -0500
committerRapptz <[email protected]>2019-02-23 04:10:10 -0500
commitcaf3d17d4aa3ce45435bb96ea6d99317bfef8618 (patch)
treed8bff0494efd7ba51d011ab4b7a9d30009eeae6d /discord/ext/commands/context.py
parent[commands] Fix up wording on HelpFormatter.get_ending_note (diff)
downloaddiscord.py-caf3d17d4aa3ce45435bb96ea6d99317bfef8618.tar.xz
discord.py-caf3d17d4aa3ce45435bb96ea6d99317bfef8618.zip
Rework entire cog system and partially document it and extensions.
Diffstat (limited to 'discord/ext/commands/context.py')
-rw-r--r--discord/ext/commands/context.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/discord/ext/commands/context.py b/discord/ext/commands/context.py
index ea193696..bef94f04 100644
--- a/discord/ext/commands/context.py
+++ b/discord/ext/commands/context.py
@@ -118,8 +118,8 @@ class Context(discord.abc.Messageable):
raise TypeError('Missing command to invoke.') from None
arguments = []
- if command.instance is not None:
- arguments.append(command.instance)
+ if command.cog is not None:
+ arguments.append(command.cog)
arguments.append(self)
arguments.extend(args[1:])
@@ -195,7 +195,7 @@ class Context(discord.abc.Messageable):
if self.command is None:
return None
- return self.command.instance
+ return self.command.cog
@discord.utils.cached_property
def guild(self):