You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: discord_slash/client.py
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -441,7 +441,7 @@ def add_slash_command(self,
441
441
guild_ids: typing.List[int] =None,
442
442
options: list=None,
443
443
default_permission: bool=True,
444
-
permissions: dict=None,
444
+
permissions: typing.Dict[int, list]=None,
445
445
connector: dict=None,
446
446
has_subcommands: bool=False):
447
447
"""
@@ -463,7 +463,7 @@ def add_slash_command(self,
463
463
:type options: list
464
464
:param default_permission: Sets if users have permission to run slash command by default, when no permissions are set. Default ``True``.
465
465
:type default_permission: bool
466
-
:param permissions: Permission requirements of the slash command. Default ``None``.
466
+
:param permissions: Dictionary of permissions of the slash command. Key being target guild_id and value being a list of permissions to apply. Default ``None``.
467
467
:type permissions: dict
468
468
:param connector: Kwargs connector for the command. Default ``None``.
469
469
:type connector: dict
@@ -510,7 +510,7 @@ def add_subcommand(self,
510
510
description: str=None,
511
511
base_description: str=None,
512
512
base_default_permission: bool=True,
513
-
base_permissions: dict=None,
513
+
base_permissions: typing.Dict[int, list]=None,
514
514
subcommand_group_description: str=None,
515
515
guild_ids: typing.List[int] =None,
516
516
options: list=None,
@@ -532,8 +532,8 @@ def add_subcommand(self,
532
532
:type base_description: str
533
533
:param default_permission: Sets if users have permission to run base command by default, when no permissions are set. Default ``True``.
534
534
:type default_permission: bool
535
-
:param permissions: Permission requirements of the base command. Default ``None``.
536
-
:type permissions: dict
535
+
:param base_permissions: Dictionary of permissions of the slash command. Key being target guild_id and value being a list of permissions to apply. Default ``None``.
536
+
:type base_permissions: dict
537
537
:param subcommand_group_description: Description of the subcommand_group. Default ``None``.
538
538
:type subcommand_group_description: str
539
539
:param guild_ids: List of guild ID of where the command will be used. Default ``None``, which will be global command.
:param default_permission: Sets if users have permission to run slash command by default, when no permissions are set. Default ``True``.
40
40
:type default_permission: bool
41
-
:param permissions: Permission requirements of the slash command. Default ``None``.
41
+
:param permissions: Dictionary of permissions of the slash command. Key being target guild_id and value being a list of permissions to apply. Default ``None``.
42
42
:type permissions: dict
43
43
:param connector: Kwargs connector for the command. Default ``None``.
:param base_default_permission: Sets if users have permission to run slash command by default, when no permissions are set. Default ``True``.
109
109
:type base_default_permission: bool
110
-
:param base_permissions: Permission requirements of the slash command. Default ``None``.
110
+
:param base_permissions: Dictionary of permissions of the slash command. Key being target guild_id and value being a list of permissions to apply. Default ``None``.
111
111
:type base_permissions: dict
112
112
:param subcommand_group_description: Description of the subcommand_group. Default ``None``.
0 commit comments