From 69348e93396cb29c56607f321f3a828770380c21 Mon Sep 17 00:00:00 2001 From: SantaSpeen Date: Tue, 18 Jul 2023 22:33:49 +0300 Subject: [PATCH] Some fixes in onChatReceive --- src/core/Client.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/core/Client.py b/src/core/Client.py index 336777b..f39bb04 100644 --- a/src/core/Client.py +++ b/src/core/Client.py @@ -453,12 +453,7 @@ class Client: message = ev_data["message"] to_all = ev_data.get("to_all") if to_all is None: - if need_send: - need_send = False to_all = True - if to_all: - if need_send: - need_send = False to_self = ev_data.get("to_self") if to_self is None: to_self = True @@ -467,6 +462,7 @@ class Client: if to_client: writer = to_client._writer await self._send(f"C:{message}", to_all=to_all, to_self=to_self, writer=writer) + need_send = False except KeyError | AttributeError: self.log.error(f"Returns invalid data: {ev_data}") if need_send: