Reformat project
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import main
|
||||
from core.bot import deliverRelayCommands
|
||||
from utils.deliver_relay_commands import deliverRelayCommands
|
||||
|
||||
|
||||
class DisableCommand:
|
||||
@@ -19,13 +19,13 @@ class DisableCommand:
|
||||
name = spl[1] + spl[2]
|
||||
if not spl[1] in main.IRCPool.keys():
|
||||
info("Note - instance not running, proceeding anyway")
|
||||
if not relayNum in main.network[spl[1]].relays.keys():
|
||||
if relayNum not in main.network[spl[1]].relays.keys():
|
||||
failure("No such relay: %s in network %s" % (spl[2], spl[1]))
|
||||
return
|
||||
main.network[spl[1]].relays[relayNum]["enabled"] = False
|
||||
user = main.alias[relayNum]["nick"]
|
||||
network = spl[1]
|
||||
relay = main.network[spl[1]].relays[relayNum]
|
||||
# relay = main.network[spl[1]].relays[relayNum]
|
||||
commands = {"status": ["Disconnect"]}
|
||||
deliverRelayCommands(relayNum, commands, user=user + "/" + network)
|
||||
main.saveConf("network")
|
||||
|
||||
Reference in New Issue
Block a user