Fix cog_app_command_error for groups

This commit is contained in:
Stocker
2022-07-27 00:29:53 -04:00
committed by GitHub
parent b80cb47caf
commit 6d1069e789
2 changed files with 14 additions and 5 deletions

View File

@@ -1269,6 +1269,10 @@ class Group:
raise ValueError('groups can only be nested at most one level')
parent.add_command(self)
self.__app_commands_error_handler__: Optional[
Callable[[Interaction, AppCommandError], Coroutine[Any, Any, None]]
] = None
def __set_name__(self, owner: Type[Any], name: str) -> None:
self._attr = name
self.module = owner.__module__