3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-27 21:19:31 +01:00

ts6: fix incorrect WHOIS syntax

Thanks to @cooper for reporting.
This commit is contained in:
James Lu 2016-06-22 18:34:07 -07:00
parent 1ad8b2e539
commit 6060a8857f

View File

@ -631,7 +631,11 @@ class TS6Protocol(TS6BaseProtocol):
Note: The core of WHOIS handling is done by coreplugin.py
(IRCd-independent), and not here."""
# <- :42XAAAAAB WHOIS 5PYAAAAAA :pylink-devel
return {'target': args[0]}
# First argument is the server that should reply to the WHOIS request
# or the server hosting the UID given. We can safely assume that any
# WHOIS commands received are for US, since we can't host any servers
# behind us to route it to.
return {'target': self.irc.nickToUid(args[-1])}
def handle_472(self, numeric, command, args):
"""Handles the incoming 472 numeric.