Fix modlog detecting bad edits from bots
This commit is contained in:
parent
fd4dd7262e
commit
8de38b17df
1 changed files with 1 additions and 2 deletions
|
@ -1,7 +1,6 @@
|
|||
import discord
|
||||
from discord.ext import commands
|
||||
|
||||
from jarvis.config import get_config
|
||||
from jarvis.db.types import Setting
|
||||
from jarvis.utils import build_embed
|
||||
from jarvis.utils.field import Field
|
||||
|
@ -15,7 +14,7 @@ class ModlogMessageCog(commands.Cog):
|
|||
async def on_message_edit(
|
||||
self, before: discord.Message, after: discord.Message
|
||||
):
|
||||
if before.author != get_config().client_id:
|
||||
if not before.author.bot:
|
||||
modlog = Setting.get(guild=after.guild.id, setting="modlog")
|
||||
if modlog:
|
||||
if before.content == after.content or before.content is None:
|
||||
|
|
Loading…
Add table
Reference in a new issue