How do cogs
pass self
into command callbacks?
#945
Answered
by
EmreTech
showierdata9978
asked this question in
Q&A
-
Normally with function decorators that store the base method, and then the base method is called somewhere else without access to the class, you can't bind |
Beta Was this translation helpful? Give feedback.
Answered by
EmreTech
Dec 9, 2022
Replies: 1 comment 3 replies
-
Application commands are bound to a cog when an instance of a cog is created, so when the callback inside of an application command is called, the cog instance is the first argument passed in. |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
showierdata9978
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Application commands are bound to a cog when an instance of a cog is created, so when the callback inside of an application command is called, the cog instance is the first argument passed in.