mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-30 23:09:23 +01:00
inspircd: rewrite handle_ping to handle one-arg PING
This commit is contained in:
parent
5381e85d3c
commit
614b8b87da
@ -522,8 +522,10 @@ class InspIRCdProtocol(TS6BaseProtocol):
|
|||||||
"""Handles incoming PING commands, so we don't time out."""
|
"""Handles incoming PING commands, so we don't time out."""
|
||||||
# <- :70M PING 70M 0AL
|
# <- :70M PING 70M 0AL
|
||||||
# -> :0AL PONG 0AL 70M
|
# -> :0AL PONG 0AL 70M
|
||||||
if self.is_internal_server(args[1]):
|
if len(args) >= 2:
|
||||||
self._send_with_prefix(args[1], 'PONG %s %s' % (args[1], source), queue=False)
|
self._send_with_prefix(args[1], 'PONG %s %s' % (args[1], source), queue=False)
|
||||||
|
else:
|
||||||
|
self._send_with_prefix(self.sid, 'PONG %s' % source, queue=False)
|
||||||
|
|
||||||
def handle_fjoin(self, servernumeric, command, args):
|
def handle_fjoin(self, servernumeric, command, args):
|
||||||
"""Handles incoming FJOIN commands (InspIRCd equivalent of JOIN/SJOIN)."""
|
"""Handles incoming FJOIN commands (InspIRCd equivalent of JOIN/SJOIN)."""
|
||||||
|
Loading…
Reference in New Issue
Block a user