jabber_mirror: Change character used for loop detection
Previously, we were using U+1B80, which is 'SUNDANESE SIGN PANYECEK' (i.e., an assigned character). U+1FFFE is a non-character (i.e., free for internal use) on Plane 1. (imported from commit f93d2401733afb96b6d717a7f659c011299071df)
This commit is contained in:
parent
f239b02027
commit
6609291d54
|
@ -118,7 +118,7 @@ class JabberToZulipBot(ClientXMPP):
|
||||||
logging.exception("Error forwarding Jabber => Zulip")
|
logging.exception("Error forwarding Jabber => Zulip")
|
||||||
|
|
||||||
def private(self, msg):
|
def private(self, msg):
|
||||||
if options.mode == 'public' or msg['thread'] == u'\u1B80':
|
if options.mode == 'public' or msg['thread'] == u'\u1FFFE':
|
||||||
return
|
return
|
||||||
sender = jid_to_zulip(msg["from"])
|
sender = jid_to_zulip(msg["from"])
|
||||||
recipient = jid_to_zulip(msg["to"])
|
recipient = jid_to_zulip(msg["to"])
|
||||||
|
@ -134,7 +134,7 @@ class JabberToZulipBot(ClientXMPP):
|
||||||
logging.error(ret)
|
logging.error(ret)
|
||||||
|
|
||||||
def group(self, msg):
|
def group(self, msg):
|
||||||
if options.mode == 'personal' or msg["thread"] == u'\u1B80':
|
if options.mode == 'personal' or msg["thread"] == u'\u1FFFE':
|
||||||
return
|
return
|
||||||
|
|
||||||
subject = msg["subject"]
|
subject = msg["subject"]
|
||||||
|
@ -199,7 +199,7 @@ class ZulipToJabberBot(object):
|
||||||
mto = jabber_recipient,
|
mto = jabber_recipient,
|
||||||
mbody = msg['content'],
|
mbody = msg['content'],
|
||||||
mtype = 'groupchat')
|
mtype = 'groupchat')
|
||||||
outgoing['thread'] = u'\u1B80'
|
outgoing['thread'] = u'\u1FFFE'
|
||||||
outgoing.send()
|
outgoing.send()
|
||||||
|
|
||||||
def private_message(self, msg):
|
def private_message(self, msg):
|
||||||
|
@ -213,7 +213,7 @@ class ZulipToJabberBot(object):
|
||||||
mto = jabber_recipient,
|
mto = jabber_recipient,
|
||||||
mbody = msg['content'],
|
mbody = msg['content'],
|
||||||
mtype = 'chat')
|
mtype = 'chat')
|
||||||
outgoing['thread'] = u'\u1B80'
|
outgoing['thread'] = u'\u1FFFE'
|
||||||
outgoing.send()
|
outgoing.send()
|
||||||
|
|
||||||
def process_subscription(self, event):
|
def process_subscription(self, event):
|
||||||
|
|
Loading…
Reference in a new issue