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

Move numericServer to ts6_common

This commit is contained in:
James Lu 2015-11-11 19:40:10 -08:00
parent 5027feb553
commit eeedeb0135
2 changed files with 5 additions and 5 deletions

View File

@ -239,11 +239,6 @@ class TS6Protocol(TS6BaseProtocol):
else:
self._send(source, 'PING %s' % source)
def numericServer(self, source, numeric, target, text):
"""Sends raw numerics from a server to a remote client, used for WHOIS
replies."""
self._send(source, '%s %s %s' % (numeric, target, text))
def awayClient(self, source, text):
"""Sends an AWAY message from a PyLink client. <text> can be an empty string
to unset AWAY status."""

View File

@ -28,6 +28,11 @@ class TS6BaseProtocol(Protocol):
### OUTGOING COMMANDS
def numericServer(self, source, numeric, target, text):
"""Sends raw numerics from a server to a remote client, used for WHOIS
replies."""
self._send(source, '%s %s %s' % (numeric, target, text))
def _sendKick(self, numeric, channel, target, reason=None):
"""Internal function to send kicks from a PyLink client/server."""
channel = utils.toLower(self.irc, channel)