forked from sh-edraft.de/sh_discord_bot
Migrated purge command
This commit is contained in:
parent
a939c741cb
commit
0dbf33a39f
@ -35,12 +35,14 @@ class PurgeCommand(DiscordCommandABC):
|
|||||||
|
|
||||||
self._logger.trace(__name__, f'Loaded command service: {type(self).__name__}')
|
self._logger.trace(__name__, f'Loaded command service: {type(self).__name__}')
|
||||||
|
|
||||||
@commands.command()
|
@commands.hybrid_command()
|
||||||
@commands.guild_only()
|
@commands.guild_only()
|
||||||
async def purge(self, ctx: Context):
|
async def purge(self, ctx: Context):
|
||||||
self._logger.debug(__name__, f'Received command purge {ctx}')
|
self._logger.debug(__name__, f'Received command purge {ctx}')
|
||||||
self._client_utils.received_command(ctx.guild.id)
|
if not await self._client_utils.check_if_bot_is_ready_yet_and_respond(ctx):
|
||||||
|
return
|
||||||
|
|
||||||
|
self._client_utils.received_command(ctx.guild.id)
|
||||||
server_settings: ServerSettings = self._config.get_configuration(f'ServerSettings_{ctx.guild.id}')
|
server_settings: ServerSettings = self._config.get_configuration(f'ServerSettings_{ctx.guild.id}')
|
||||||
|
|
||||||
if not self._permissions.is_member_moderator(ctx.author):
|
if not self._permissions.is_member_moderator(ctx.author):
|
||||||
|
Loading…
Reference in New Issue
Block a user