Skip to content

Commit 8e6089b

Browse files
ToothyDevplun1331
andauthored
Apply suggestions from code review
Co-authored-by: plun1331 <plun1331@gmail.com> Signed-off-by: ToothyDev <55001472+ToothyDev@users.noreply.github.com>
1 parent dc45c8c commit 8e6089b

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

discord/bot.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -915,6 +915,7 @@ async def callback() -> None:
915915

916916
def slash_command(
917917
self,
918+
*,
918919
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
919920
cog: Cog | None = MISSING,
920921
contexts: set[InteractionContextType] | None = MISSING,
@@ -964,6 +965,7 @@ def slash_command(
964965

965966
def user_command(
966967
self,
968+
*,
967969
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
968970
cog: Cog | None = MISSING,
969971
contexts: set[InteractionContextType] | None = MISSING,
@@ -1005,6 +1007,7 @@ def user_command(
10051007

10061008
def message_command(
10071009
self,
1010+
*,
10081011
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
10091012
cog: Cog | None = MISSING,
10101013
contexts: set[InteractionContextType] | None = MISSING,
@@ -1046,6 +1049,7 @@ def message_command(
10461049

10471050
def application_command(
10481051
self,
1052+
*,
10491053
cls: type[C] = SlashCommand,
10501054
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
10511055
cog: Cog | None = MISSING,

discord/commands/core.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1980,6 +1980,7 @@ def _update_copy(self, kwargs: dict[str, Any]):
19801980

19811981

19821982
def slash_command(
1983+
*,
19831984
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
19841985
cog: Cog | None = MISSING,
19851986
contexts: set[InteractionContextType] | None = MISSING,
@@ -2026,6 +2027,7 @@ def slash_command(
20262027

20272028

20282029
def user_command(
2030+
*,
20292031
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
20302032
cog: Cog | None = MISSING,
20312033
contexts: set[InteractionContextType] | None = MISSING,
@@ -2064,6 +2066,7 @@ def user_command(
20642066

20652067

20662068
def message_command(
2069+
*,
20672070
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
20682071
cog: Cog | None = MISSING,
20692072
contexts: set[InteractionContextType] | None = MISSING,
@@ -2102,6 +2105,7 @@ def message_command(
21022105

21032106

21042107
def application_command(
2108+
*,
21052109
cls=SlashCommand,
21062110
checks: list[Callable[[ApplicationContext], bool]] | None = MISSING,
21072111
cog: Cog | None = MISSING,

0 commit comments

Comments
 (0)