Skip to content

Commit 5e61daf

Browse files
committed
add support for passing options in SlashCommand.__init__
1 parent 92f26c2 commit 5e61daf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

discord/commands/commands.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ def __init__(self, func: Callable, *args, **kwargs) -> None:
390390
self.cog = None
391391

392392
params = self._get_signature_parameters()
393-
self.options: List[Option] = self._parse_options(params)
393+
self.options: List[Option] = kwargs.get('options') or self._parse_options(params)
394394

395395
try:
396396
checks = func.__commands_checks__

0 commit comments

Comments
 (0)