[cmd_server] launch and disconnect function doesn't exist anymore
This commit is contained in:
parent
093581f646
commit
63cc770800
@ -43,12 +43,12 @@ def close(data, toks, context, prompt):
|
|||||||
if len(toks) > 1:
|
if len(toks) > 1:
|
||||||
for s in toks[1:]:
|
for s in toks[1:]:
|
||||||
if s in servers:
|
if s in servers:
|
||||||
context.servers[s].disconnect()
|
context.servers[s].close()
|
||||||
del context.servers[s]
|
del context.servers[s]
|
||||||
else:
|
else:
|
||||||
print ("close: server `%s' not found." % s)
|
print ("close: server `%s' not found." % s)
|
||||||
elif prompt.selectedServer is not None:
|
elif prompt.selectedServer is not None:
|
||||||
prompt.selectedServer.disconnect()
|
prompt.selectedServer.close()
|
||||||
del prompt.servers[selectedServer.id]
|
del prompt.servers[selectedServer.id]
|
||||||
prompt.selectedServer = None
|
prompt.selectedServer = None
|
||||||
return
|
return
|
||||||
@ -60,12 +60,12 @@ def connect(data, toks, context, prompt):
|
|||||||
if len(toks) > 1:
|
if len(toks) > 1:
|
||||||
for s in toks[1:]:
|
for s in toks[1:]:
|
||||||
if s in context.servers:
|
if s in context.servers:
|
||||||
context.servers[s].launch(context.receive_message)
|
context.servers[s].open()
|
||||||
else:
|
else:
|
||||||
print ("connect: server `%s' not found." % s)
|
print ("connect: server `%s' not found." % s)
|
||||||
|
|
||||||
elif prompt.selectedServer is not None:
|
elif prompt.selectedServer is not None:
|
||||||
prompt.selectedServer.launch(context.receive_message)
|
prompt.selectedServer.open()
|
||||||
else:
|
else:
|
||||||
print (" Please SELECT a server or give its name in argument.")
|
print (" Please SELECT a server or give its name in argument.")
|
||||||
|
|
||||||
@ -76,12 +76,12 @@ def disconnect(data, toks, context, prompt):
|
|||||||
if len(toks) > 1:
|
if len(toks) > 1:
|
||||||
for s in toks[1:]:
|
for s in toks[1:]:
|
||||||
if s in context.servers:
|
if s in context.servers:
|
||||||
if not context.servers[s].disconnect():
|
if not context.servers[s].close():
|
||||||
print ("disconnect: server `%s' already disconnected." % s)
|
print ("disconnect: server `%s' already disconnected." % s)
|
||||||
else:
|
else:
|
||||||
print ("disconnect: server `%s' not found." % s)
|
print ("disconnect: server `%s' not found." % s)
|
||||||
elif prompt.selectedServer is not None:
|
elif prompt.selectedServer is not None:
|
||||||
if not prompt.selectedServer.disconnect():
|
if not prompt.selectedServer.close():
|
||||||
print ("disconnect: server `%s' already disconnected."
|
print ("disconnect: server `%s' already disconnected."
|
||||||
% prompt.selectedServer.id)
|
% prompt.selectedServer.id)
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user