Skip to content

Commit 0a928be

Browse files
authored
Fix bridge command detection in cogs (#1592)
Use updated method to retrieve command variants
1 parent d6b91cf commit 0a928be

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

discord/cog.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,8 @@ def __new__(cls: Type[CogMeta], *args: Any, **kwargs: Any) -> CogMeta:
204204
if elem.startswith(("cog_", "bot_")):
205205
raise TypeError(no_bot_cog.format(base, elem))
206206

207-
commands[f"ext_{elem}"] = value.get_ext_command()
208-
commands[f"application_{elem}"] = value.get_application_command()
207+
commands[f"ext_{elem}"] = value.ext_variant
208+
commands[f"application_{elem}"] = value.slash_variant
209209
except AttributeError:
210210
# we are confident that the value is not a Bridge Command
211211
pass

0 commit comments

Comments
 (0)