mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-09-05 01:16:21 +00:00
First pass at supporting user apps
Co-authored-by: red <red@kalab.sk> Co-authored-by: Vioshim <63890837+Vioshim@users.noreply.github.com>
This commit is contained in:
@ -653,6 +653,8 @@ class HybridGroup(Group[CogT, P, T]):
|
||||
guild_only = getattr(self.callback, '__discord_app_commands_guild_only__', False)
|
||||
default_permissions = getattr(self.callback, '__discord_app_commands_default_permissions__', None)
|
||||
nsfw = getattr(self.callback, '__discord_app_commands_is_nsfw__', False)
|
||||
contexts = getattr(self.callback, '__discord_app_commands_contexts__', MISSING)
|
||||
installs = getattr(self.callback, '__discord_app_commands_installation_types__', MISSING)
|
||||
self.app_command = app_commands.Group(
|
||||
name=self._locale_name or self.name,
|
||||
description=self._locale_description or self.description or self.short_doc or '…',
|
||||
@ -660,6 +662,8 @@ class HybridGroup(Group[CogT, P, T]):
|
||||
guild_only=guild_only,
|
||||
default_permissions=default_permissions,
|
||||
nsfw=nsfw,
|
||||
allowed_installs=installs,
|
||||
allowed_contexts=contexts,
|
||||
)
|
||||
|
||||
# This prevents the group from re-adding the command at __init__
|
||||
|
Reference in New Issue
Block a user