changeset 3405e0919e42 in /home/hg/repos/python-nbxmpp

details:http://hg.gajim.org/python-nbxmpp?cmd=changeset;node=3405e0919e42
description: fix encoding Protocol object before sending them

diffstat:

 nbxmpp/transports_nb.py |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (17 lines):

diff -r 3503b0321a4f -r 3405e0919e42 nbxmpp/transports_nb.py
--- a/nbxmpp/transports_nb.py   Tue Jul 30 22:23:36 2013 +0200
+++ b/nbxmpp/transports_nb.py   Wed Jul 31 10:07:57 2013 +0200
@@ -497,10 +497,10 @@
         """
         NonBlockingTransport.send(self, raw_data, now)
 
-        if isinstance(raw_data, str):
+        if isinstance(raw_data, bytes):
+            r = raw_data
+        else:
             r = self.encode_stanza(raw_data)
-        else:
-            r = raw_data
 
         if now:
             self.sendqueue.insert(0, r)
_______________________________________________
Commits mailing list
[email protected]
http://lists.gajim.org/cgi-bin/listinfo/commits

Reply via email to