From ca1cc73c79e1adc3653cb4452c4f1eee9b58365a Mon Sep 17 00:00:00 2001 From: mathieui Date: Mon, 5 Jul 2021 22:41:49 +0200 Subject: [PATCH] xmlstream: refine type check --- slixmpp/xmlstream/xmlstream.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slixmpp/xmlstream/xmlstream.py b/slixmpp/xmlstream/xmlstream.py index c21cc954..30f99071 100644 --- a/slixmpp/xmlstream/xmlstream.py +++ b/slixmpp/xmlstream/xmlstream.py @@ -1254,7 +1254,7 @@ class XMLStream(asyncio.BaseProtocol): else: str_data = data self.send_raw(str_data) - else: + elif isinstance(data, (str, bytes)): self.send_raw(data) except ContinueQueue as exc: log.debug('Stanza in send queue not sent: %s', exc)