From f55d3b41b07f658f8420efe1242c6b411faf642c Mon Sep 17 00:00:00 2001 From: Cyberes Date: Sun, 19 Mar 2023 19:52:46 -0600 Subject: [PATCH] fix threaded replies in DM? --- matrix_gpt/bot/callbacks.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/matrix_gpt/bot/callbacks.py b/matrix_gpt/bot/callbacks.py index b21a34e..3aec0b8 100644 --- a/matrix_gpt/bot/callbacks.py +++ b/matrix_gpt/bot/callbacks.py @@ -130,7 +130,7 @@ class Callbacks: asyncio.get_event_loop().create_task(inner()) return - elif msg.startswith(f'{self.command_prefix} ') or room.member_count == 2: + elif (msg.startswith(f'{self.command_prefix} ') or room.member_count == 2) and not is_thread(event): # Otherwise if this is in a 1-1 with the bot or features a command prefix, treat it as a command. msg = msg if not msg.startswith(self.command_prefix) else msg[len(self.command_prefix):].strip() # Remove the command prefix command = Command(