From 95481e64b2ee226ba97fab70c98a6e284b1af347 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maxime=20=E2=80=9Cpep=E2=80=9D=20Buquet?= Date: Tue, 13 Jul 2021 23:15:02 +0200 Subject: [PATCH] decrypt_message: don't always send heartbeat MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Maxime “pep” Buquet --- slixmpp_omemo/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slixmpp_omemo/__init__.py b/slixmpp_omemo/__init__.py index 0ecb0d2..3c2f689 100644 --- a/slixmpp_omemo/__init__.py +++ b/slixmpp_omemo/__init__.py @@ -643,7 +643,7 @@ class XEP_0384(BasePlugin): finally: asyncio.ensure_future(self._publish_bundle()) - if self.auto_heartbeat: + if self.auto_heartbeat and self.should_heartbeat(): msg = self.make_heartbeat(jid) msg.send()