mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-24 03:29:28 +01:00
hybrid: Reorder a little, send EOB right after sending SERVER
This commit is contained in:
parent
c4608fb891
commit
c71010f1b0
@ -98,6 +98,9 @@ class HybridProtocol(TS6BaseProtocol):
|
||||
f('SERVER %s 0 :%s' % (self.irc.serverdata["hostname"],
|
||||
self.irc.serverdata.get('serverdesc') or self.irc.botdata['serverdesc']))
|
||||
|
||||
# send endburst now
|
||||
self.irc.send(':%s EOB' % (self.irc.sid,))
|
||||
|
||||
def spawnClient(self, nick, ident='null', host='null', realhost=None, modes=set(),
|
||||
server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None,
|
||||
manipulatable=False):
|
||||
@ -260,12 +263,6 @@ class HybridProtocol(TS6BaseProtocol):
|
||||
self.irc.callHooks([uid, 'CLIENT_OPERED', {'text': 'IRC_Operator'}])
|
||||
return {'uid': uid, 'ts': ts, 'nick': nick, 'realname': realname, 'host': host, 'ident': ident, 'ip': ip}
|
||||
|
||||
def handle_svstag(self, numeric, command, args):
|
||||
tag = args[2]
|
||||
if tag in ['313']:
|
||||
return
|
||||
raise Exception('COULD NOT PARSE SVSTAG: {} {} {}'.format(numeric, command, args))
|
||||
|
||||
def handle_join(self, numeric, command, args):
|
||||
"""Handles incoming channel JOINs."""
|
||||
# parameters: channelTS, channel, '+' (a plus sign)
|
||||
@ -352,10 +349,6 @@ class HybridProtocol(TS6BaseProtocol):
|
||||
log.debug('(%s) Set self.irc.lastping.', self.irc.name)
|
||||
self.irc.lastping = time.time()
|
||||
|
||||
def handle_endburst(self, numeric, command, args):
|
||||
self.irc.send(':%s EOB' % (self.irc.sid,))
|
||||
pass
|
||||
|
||||
def handle_mode(self, numeric, command, args):
|
||||
# <- :0UYAAAAAD MODE 0UYAAAAAD :-i
|
||||
target = args[0]
|
||||
@ -381,6 +374,15 @@ class HybridProtocol(TS6BaseProtocol):
|
||||
return {'target': channel, 'modes': changedmodes, 'ts': ts,
|
||||
'oldchan': oldobj}
|
||||
|
||||
def handle_svstag(self, numeric, command, args):
|
||||
tag = args[2]
|
||||
if tag in ['313']:
|
||||
return
|
||||
raise Exception('COULD NOT PARSE SVSTAG: {} {} {}'.format(numeric, command, args))
|
||||
|
||||
def handle_endburst(self, numeric, command, args):
|
||||
pass
|
||||
|
||||
# empty handlers
|
||||
# TODO: there's a better way to do this
|
||||
def handle_globops(self, numeric, command, args):
|
||||
|
Loading…
Reference in New Issue
Block a user