mirror of
https://github.com/jlu5/PyLink.git
synced 2024-12-24 19:52:53 +01:00
ts6_common: fix outbound kicks to PUIDS not updating the state
This was previously trying to update the state based on the user's nick, but we use PUIDs internally. In other words, make sure that we don't replace the internal target when sending the outgoing text...
This commit is contained in:
parent
fccec3a195
commit
8465edd5af
@ -144,9 +144,9 @@ class TS6BaseProtocol(IRCS2SProtocol):
|
||||
reason = 'No reason given'
|
||||
|
||||
# Mangle kick targets for IRCds that require it.
|
||||
target = self._expandPUID(target)
|
||||
real_target = self._expandPUID(target)
|
||||
|
||||
self._send(numeric, 'KICK %s %s :%s' % (channel, target, reason))
|
||||
self._send(numeric, 'KICK %s %s :%s' % (channel, real_target, reason))
|
||||
|
||||
# We can pretend the target left by its own will; all we really care about
|
||||
# is that the target gets removed from the channel userlist, and calling
|
||||
@ -377,6 +377,7 @@ class TS6BaseProtocol(IRCS2SProtocol):
|
||||
except IndexError:
|
||||
reason = ''
|
||||
|
||||
log.debug('(%s) Removing kick target %s from %s', self.irc.name, kicked, channel)
|
||||
self.handle_part(kicked, 'KICK', [channel, reason])
|
||||
return {'channel': channel, 'target': kicked, 'text': reason}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user