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

Remove endburst toggling in spawnServer, has_bursted IrcServer flag

Neither are being used at all; they're essentially dead code.
This commit is contained in:
James Lu 2015-07-22 20:39:38 -07:00
parent 35cdfbf7e6
commit 686467ffa6
3 changed files with 3 additions and 9 deletions

View File

@ -39,7 +39,6 @@ class IrcServer():
self.users = [] self.users = []
self.internal = internal self.internal = internal
self.name = name.lower() self.name = name.lower()
self.has_bursted = False
def __repr__(self): def __repr__(self):
return repr(self.__dict__) return repr(self.__dict__)

View File

@ -561,7 +561,7 @@ def handle_events(irc, data):
if parsed_args is not None: if parsed_args is not None:
return [numeric, command, parsed_args] return [numeric, command, parsed_args]
def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server', endburst=True): def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server'):
# -> :0AL SERVER test.server * 1 0AM :some silly pseudoserver # -> :0AL SERVER test.server * 1 0AM :some silly pseudoserver
uplink = uplink or irc.sid uplink = uplink or irc.sid
name = name.lower() name = name.lower()
@ -580,13 +580,8 @@ def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server', endburst
raise ValueError('Invalid server name %r' % name) raise ValueError('Invalid server name %r' % name)
_send(irc, uplink, 'SERVER %s * 1 %s :%s' % (name, sid, desc)) _send(irc, uplink, 'SERVER %s * 1 %s :%s' % (name, sid, desc))
irc.servers[sid] = IrcServer(uplink, name, internal=True) irc.servers[sid] = IrcServer(uplink, name, internal=True)
if endburst:
endburstServer(irc, sid)
return sid
def endburstServer(irc, sid):
_send(irc, sid, 'ENDBURST') _send(irc, sid, 'ENDBURST')
irc.servers[sid].has_bursted = True return sid
def handle_ftopic(irc, numeric, command, args): def handle_ftopic(irc, numeric, command, args):
# <- :70M FTOPIC #channel 1434510754 GLo|o|!GLolol@escape.the.dreamland.ca :Some channel topic # <- :70M FTOPIC #channel 1434510754 GLo|o|!GLolol@escape.the.dreamland.ca :Some channel topic

View File

@ -527,7 +527,7 @@ def handle_events(irc, data):
if parsed_args is not None: if parsed_args is not None:
return [numeric, command, parsed_args] return [numeric, command, parsed_args]
def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server', endburst=True): def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server'):
# -> :0AL SERVER test.server 1 0XY :some silly pseudoserver # -> :0AL SERVER test.server 1 0XY :some silly pseudoserver
uplink = uplink or irc.sid uplink = uplink or irc.sid
name = name.lower() name = name.lower()