3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-27 13:09:23 +01:00

relay: on Clientbot networks, don't relay prefix mode changes for the relayer bot

Closes #366.
This commit is contained in:
James Lu 2017-01-06 16:45:48 -08:00
parent 43002d466e
commit 3e706366bd

View File

@ -776,6 +776,12 @@ def get_supported_cmodes(irc, remoteirc, channel, modes):
"for network %r.",
irc.name, modechar, arg, remoteirc.name)
if irc.protoname == 'clientbot' and irc.pseudoclient and arg == irc.pseudoclient.uid:
# Skip modesync on the main PyLink client.
log.debug("(%s) relay.get_supported_cmodes: filtering prefix change (%r, %r) on Clientbot relayer",
irc.name, name, arg)
break
# If the target is a remote user, get the real target
# (original user).
arg = get_orig_user(irc, arg, targetirc=remoteirc) or \