Skip to content

Commit

Permalink
catch unbound
Browse files Browse the repository at this point in the history
  • Loading branch information
MattBSG committed Jul 13, 2024
1 parent 484058b commit 408a5a3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cogs/modmail.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def __init__(self, bot):
@app_commands.describe(delay='The delay for the modmail to close, in 1w2d3h4m5s format')
@app_commands.guilds(discord.Object(id=config.guild))
@app_commands.default_permissions(view_audit_log=True)
async def _close(self, interaction: discord.Interaction, delay: typing.Optional[str], auto: bool = False):
async def _close(self, interaction: discord.Interaction, delay: typing.Optional[str]):
if not delay:
await interaction.response.send_message(
f'This thread has been closed by {interaction.user}. Use `/open` to send any followup messages to this user.'
Expand All @@ -68,7 +68,7 @@ async def _close(self, interaction: discord.Interaction, delay: typing.Optional[
ephemeral=True,
)

if delay:
if delay and scheduledTime:
await interaction.followup.send(
f'Thread has been scheduled to be closed {scheduledTime} by {interaction.user}. Once closed, use `/open` to send any followup messages to this user.'
)
Expand Down

0 comments on commit 408a5a3

Please sign in to comment.