aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Den4200 <[email protected]>2021-03-28 11:58:01 -0400
committerGravatar Den4200 <[email protected]>2021-03-28 11:58:01 -0400
commit14514d1ed15e9155ef8700473cd0953126421177 (patch)
tree811c5c4363055b7fb8bdca43085ca0f9b6e2ab98
parentAdded a newline to space out some code. (diff)
Account for requesting the bot's DMs with itself.
-rw-r--r--bot/exts/moderation/dm_relay.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bot/exts/moderation/dm_relay.py b/bot/exts/moderation/dm_relay.py
index 1d57862d9..ed1c45292 100644
--- a/bot/exts/moderation/dm_relay.py
+++ b/bot/exts/moderation/dm_relay.py
@@ -22,7 +22,7 @@ class DMRelay(Cog):
"""Relays the direct message history between the bot and given user."""
log.trace(f"Relaying DMs with {user.name} ({user.id})")
- if not user.dm_channel:
+ if self.bot.user == user or not user.dm_channel:
await ctx.send(f"{Emojis.cross_mark} No direct message history with {user.mention}.")
return