Skip to content

Commit 56df6da

Browse files
committed
fix redirect
1 parent 50737d0 commit 56df6da

File tree

1 file changed

+16
-12
lines changed

1 file changed

+16
-12
lines changed

modules/help_channels/message_commands/redirect.py

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -28,18 +28,22 @@ def __init__(self, bot):
2828

2929
@commands.message_command(name="Redirect to help channel")
3030
async def redirect(self, inter: disnake.MessageCommandInteraction):
31-
if inter.target.channel.parent.id in variables.help_channels + [1143095605577654392]:
32-
embed = disnake.Embed(
33-
title="This is the wrong channel.",
34-
description=WRONG_CHANNEL_MESSAGE,
35-
color=disnake.Colour.red()
36-
)
37-
else:
38-
embed = disnake.Embed(
39-
title="Please ask this in the help channels!",
40-
description=MESSAGE,
41-
colour=disnake.Colour.orange(),
42-
)
31+
embed = disnake.Embed(
32+
title="Please ask this in the help channels!",
33+
description=MESSAGE,
34+
colour=disnake.Colour.orange(),
35+
)
36+
37+
# python :D :D :D
38+
try:
39+
if inter.target.channel.parent.id in variables.help_channels + [1143095605577654392]:
40+
embed = disnake.Embed(
41+
title="This is the wrong channel.",
42+
description=WRONG_CHANNEL_MESSAGE,
43+
color=disnake.Colour.red()
44+
)
45+
except:
46+
pass
4347

4448
embed.set_footer(
4549
text="Requested by " + inter.author.display_name,

0 commit comments

Comments
 (0)