mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-01 09:19:23 +01:00
inspircd: fix logic for tracking existing bans in sjoin()
This commit is contained in:
parent
6555ba2e6a
commit
77e13bce03
@ -111,9 +111,11 @@ class InspIRCdProtocol(TS6BaseProtocol):
|
|||||||
regularmodes = []
|
regularmodes = []
|
||||||
for mode in modes:
|
for mode in modes:
|
||||||
modechar = mode[0][-1]
|
modechar = mode[0][-1]
|
||||||
# Don't reset bans that have already been set
|
if modechar in self.irc.cmodes['*A']:
|
||||||
if modechar in self.irc.cmodes['*A'] and (modechar, mode[1]) not in self.irc.channels[channel].modes:
|
# Track bans separately (they are sent as a normal FMODE instead of in FJOIN.
|
||||||
banmodes.append(mode)
|
# However, don't reset bans that have already been set.
|
||||||
|
if (modechar, mode[1]) not in self.irc.channels[channel].modes:
|
||||||
|
banmodes.append(mode)
|
||||||
else:
|
else:
|
||||||
regularmodes.append(mode)
|
regularmodes.append(mode)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user