diff --git a/main.py b/main.py index fe28bf2..af3ca48 100644 --- a/main.py +++ b/main.py @@ -297,6 +297,10 @@ async def message_callback(room: nio.MatrixRoom, event: nio.RoomMessageText) -> global client, settings, emojis if settings["debug"]: print(f"Message received in room {room.display_name}\n{event.sender} | {event.body}") + # Discord messages need different treatment. Absolutely no commands, and if possible no instant message edits. + # Because selfbots are against ToS on Discord, and will get banned within just a few hours to days of usage. + if " (Discord)" in room.display_name: + return admin = False if event.sender == client.user_id: # If this is our message admin = True