mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-01 01:09:22 +01:00
protocols: respect serverdesc config options in spawnServer
This commit is contained in:
parent
759f6c4492
commit
72cfe04904
@ -425,10 +425,11 @@ def handle_events(irc, data):
|
||||
if parsed_args is not None:
|
||||
return [numeric, command, parsed_args]
|
||||
|
||||
def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server'):
|
||||
def spawnServer(irc, name, sid=None, uplink=None, desc=None):
|
||||
# -> :0AL SERVER test.server * 1 0AM :some silly pseudoserver
|
||||
uplink = uplink or irc.sid
|
||||
name = name.lower()
|
||||
desc = desc or irc.serverdata.get('serverdesc') or irc.botdata['serverdesc']
|
||||
if sid is None: # No sid given; generate one!
|
||||
irc.sidgen = utils.TS6SIDGenerator(irc.serverdata["sidrange"])
|
||||
sid = irc.sidgen.next_sid()
|
||||
|
@ -575,10 +575,11 @@ def handle_events(irc, data):
|
||||
if parsed_args is not None:
|
||||
return [numeric, command, parsed_args]
|
||||
|
||||
def spawnServer(irc, name, sid=None, uplink=None, desc='PyLink Server'):
|
||||
def spawnServer(irc, name, sid=None, uplink=None, desc=None):
|
||||
# -> :0AL SID test.server 1 0XY :some silly pseudoserver
|
||||
uplink = uplink or irc.sid
|
||||
name = name.lower()
|
||||
desc = desc or irc.serverdata.get('serverdesc') or irc.botdata['serverdesc']
|
||||
if sid is None: # No sid given; generate one!
|
||||
irc.sidgen = utils.TS6SIDGenerator(irc.serverdata["sidrange"])
|
||||
sid = irc.sidgen.next_sid()
|
||||
|
Loading…
Reference in New Issue
Block a user