mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 03:08:55 -05:00
[V3 Mod] Fix unban and case numbering problems (#1101)
* [ModLog] fix case numbering issue * [Mod] fix unban command
This commit is contained in:
parent
02d3aec33e
commit
69c50591b2
@ -522,7 +522,7 @@ class Mod:
|
|||||||
click the user and select 'Copy ID'."""
|
click the user and select 'Copy ID'."""
|
||||||
guild = ctx.guild
|
guild = ctx.guild
|
||||||
author = ctx.author
|
author = ctx.author
|
||||||
user = self.bot.get_user_info(user_id)
|
user = await self.bot.get_user_info(user_id)
|
||||||
if not user:
|
if not user:
|
||||||
await ctx.send(_("Couldn't find a user with that ID!"))
|
await ctx.send(_("Couldn't find a user with that ID!"))
|
||||||
return
|
return
|
||||||
|
|||||||
@ -311,6 +311,7 @@ async def get_next_case_number(guild: discord.Guild) -> str:
|
|||||||
"""
|
"""
|
||||||
cases = sorted(
|
cases = sorted(
|
||||||
(await _conf.guild(guild).get_attr("cases")),
|
(await _conf.guild(guild).get_attr("cases")),
|
||||||
|
key=lambda x: int(x),
|
||||||
reverse=True
|
reverse=True
|
||||||
)
|
)
|
||||||
return str(int(cases[0]) + 1) if cases else "1"
|
return str(int(cases[0]) + 1) if cases else "1"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user