*sigh* I'm too confused today. This is nicer.
This commit is contained in:
parent
03f64fb23c
commit
0346e29e89
|
@ -152,21 +152,20 @@ class ChatControlSession(stanza_session.EncryptedStanzaSession):
|
||||||
|
|
||||||
if msgtxt == '':
|
if msgtxt == '':
|
||||||
return
|
return
|
||||||
else:
|
elif msgtxt != None and msgtxt != '':
|
||||||
if msgtxt:
|
self.append_otr_tag = False
|
||||||
self.append_otr_tag = False
|
|
||||||
|
|
||||||
# We're also here if we just don't
|
# We're also here if we just don't
|
||||||
# support OTR. Thus, we should strip
|
# support OTR. Thus, we should strip
|
||||||
# the tags from plaintext messages
|
# the tags from plaintext messages
|
||||||
# since they look ugly.
|
# 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', '')
|
||||||
msgtxt = msgtxt.replace('\x20\x09\x20' \
|
msgtxt = msgtxt.replace('\x20\x09\x20' \
|
||||||
'\x09\x20\x20\x09\x20', '')
|
'\x09\x20\x20\x09\x20', '')
|
||||||
msgtxt = msgtxt.replace('\x20\x20\x09' \
|
msgtxt = msgtxt.replace('\x20\x20\x09' \
|
||||||
'\x09\x20\x20\x09\x20', '')
|
'\x09\x20\x20\x09\x20', '')
|
||||||
else:
|
else:
|
||||||
log_type = 'single_msg_recv'
|
log_type = 'single_msg_recv'
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue