Skip to content

Commit

Permalink
ok
Browse files Browse the repository at this point in the history
  • Loading branch information
bugsbirb committed Apr 14, 2024
1 parent fc4af7e commit 502b32f
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Cogs/Modules/staff.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,8 +369,6 @@ async def leaderboard(self, ctx: commands.Context):

@staff.command(name="leaderboard-reset", description="Reset the message quota leaderboard")
async def reset_staff_message_counts(self, ctx: commands.Context):


await ctx.defer()
if not await self.modulecheck(ctx):
await ctx.send(f"{no} **{ctx.author.display_name}**, the quota module isn't enabled.")
Expand All @@ -380,13 +378,14 @@ async def reset_staff_message_counts(self, ctx: commands.Context):
return

mccollection = dbq["messages"]
await mccollection.update_many({'guild_id': ctx.guild.id, '$set': {'message_count': 0}})
await mccollection.update_many({'guild_id': ctx.guild.id}, {'$set': {'message_count': 0}})
await ctx.send(f"{tick} **{ctx.author.display_name}**, I've reset the entire staff team's message count.")
try:
owner = ctx.guild.owner
await owner.send(f"{tick} **{ctx.guild.owner.display_name}**, `{ctx.author.display_name}` has reset the staff leaderboard.")
except Exception as e:
pass
print('Yeah I couldn\'t dm the owner but oh well.')
return



Expand Down

0 comments on commit 502b32f

Please sign in to comment.