mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-09 12:48:54 -05:00
[Mod] make [p]ban days parameter optional as per the doc (#2602)
This commit is contained in:
parent
a1b03be27e
commit
47723cee33
@ -206,9 +206,14 @@ class KickBanMixin(MixinMeta):
|
|||||||
@commands.bot_has_permissions(ban_members=True)
|
@commands.bot_has_permissions(ban_members=True)
|
||||||
@checks.admin_or_permissions(ban_members=True)
|
@checks.admin_or_permissions(ban_members=True)
|
||||||
async def ban(
|
async def ban(
|
||||||
self, ctx: commands.Context, user: discord.Member, days: int = 0, *, reason: str = None
|
self,
|
||||||
|
ctx: commands.Context,
|
||||||
|
user: discord.Member,
|
||||||
|
days: Optional[int] = 0,
|
||||||
|
*,
|
||||||
|
reason: str = None,
|
||||||
):
|
):
|
||||||
"""Ban a user from this server.
|
"""Ban a user from this server and optionally delete days of messages.
|
||||||
|
|
||||||
If days is not a number, it's treated as the first word of the reason.
|
If days is not a number, it's treated as the first word of the reason.
|
||||||
Minimum 0 days, maximum 7. Defaults to 0."""
|
Minimum 0 days, maximum 7. Defaults to 0."""
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user