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

ngircd: fill in mode definitions

Source: https://github.com/ngircd/ngircd/blob/master/doc/Modes.txt
This commit is contained in:
James Lu 2017-07-06 20:12:29 -07:00
parent 3d0ccadb76
commit 73464e516f

View File

@ -51,6 +51,18 @@ class NgIRCdProtocol(IRCS2SProtocol):
self._caps.clear() self._caps.clear()
self.cmodes.update({
'banexception': 'e', 'invex': 'I', 'regmoderated': 'M', 'nonick': 'N',
'operonly': 'O', 'permanent': 'P', 'nokick': 'Q', 'registered': 'r',
'regonly': 'R', 'noinvite': 'V', 'sslonly': 'z'
})
self.umodes.update({
'away': 'a', 'deaf': 'b', 'bot': 'B', 'sno_clientconnections': 'c',
'deaf_commonchan': 'C', 'floodexempt': 'f', 'hidechans': 'I',
'servprotect': 'q', 'restricted': 'r', 'registered': 'R', 'cloak': 'x'
})
def spawn_client(self, nick, ident='null', host='null', realhost=None, modes=set(), def spawn_client(self, nick, ident='null', host='null', realhost=None, modes=set(),
server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator',
manipulatable=False): manipulatable=False):
@ -290,7 +302,6 @@ class NgIRCdProtocol(IRCS2SProtocol):
log.debug("(%s) Ignoring KILL to %r as it isn't meant for us; we should see a QUIT soon", log.debug("(%s) Ignoring KILL to %r as it isn't meant for us; we should see a QUIT soon",
self.name, killed) self.name, killed)
def handle_nick(self, source, command, args): def handle_nick(self, source, command, args):
""" """
Handles the NICK command, used for server introductions and nick changes. Handles the NICK command, used for server introductions and nick changes.