1
Fork 0
mirror of https://github.com/wlinator/luminara.git synced 2024-10-02 18:23:12 +00:00

Refactor interaction_check method in IntroductionFinishButtons

This commit is contained in:
wlinator 2024-08-15 06:42:01 -04:00
parent 7931957ec0
commit a1bcecfc61

View file

@ -69,11 +69,10 @@ class IntroductionFinishButtons(View):
self.stop()
async def interaction_check(self, interaction: discord.Interaction) -> bool:
if interaction.user != self.ctx.author:
await interaction.response.send_message(
"You can't use these buttons.",
ephemeral=True,
)
return False
else:
if interaction.user == self.ctx.author:
return True
await interaction.response.send_message(
"You can't use these buttons.",
ephemeral=True,
)
return False