Sorry, empty messages killed OTR. Fixed.
This commit is contained in:
parent
41fe6ed927
commit
03f64fb23c
|
@ -153,12 +153,13 @@ class ChatControlSession(stanza_session.EncryptedStanzaSession):
|
||||||
if msgtxt == '':
|
if msgtxt == '':
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
|
if msgtxt:
|
||||||
self.append_otr_tag = False
|
self.append_otr_tag = False
|
||||||
|
|
||||||
# We're also here if we just don't support OTR.
|
# We're also here if we just don't
|
||||||
# Thus, we should strip the tags from plaintext
|
# support OTR. Thus, we should strip
|
||||||
# messages since they look ugly.
|
# the tags from plaintext messages
|
||||||
if msgtxt:
|
# since they look ugly.
|
||||||
msgtxt = msgtxt.replace('\x20\x09\x20' \
|
msgtxt = msgtxt.replace('\x20\x09\x20' \
|
||||||
'\x20\x09\x09\x09\x09\x20\x09' \
|
'\x20\x09\x09\x09\x09\x20\x09' \
|
||||||
'\x20\x09\x20\x09\x20\x20', '')
|
'\x20\x09\x20\x09\x20\x20', '')
|
||||||
|
|
Loading…
Reference in New Issue