Reformat code
This commit is contained in:
parent
5c63fb5048
commit
21ed66bc00
|
@ -487,7 +487,6 @@ class API(object):
|
||||||
listinfo = chankeep.getListInfo(net)
|
listinfo = chankeep.getListInfo(net)
|
||||||
return dumps({"success": True, "listinfo": listinfo})
|
return dumps({"success": True, "listinfo": listinfo})
|
||||||
|
|
||||||
|
|
||||||
@app.route("/irc/msg/<net>/<num>/<channel>/", methods=["PUT"])
|
@app.route("/irc/msg/<net>/<num>/<channel>/", methods=["PUT"])
|
||||||
@login_required
|
@login_required
|
||||||
def irc_send_message(self, request, net, num, channel):
|
def irc_send_message(self, request, net, num, channel):
|
||||||
|
@ -532,4 +531,3 @@ class API(object):
|
||||||
if name not in main.IRCPool.keys():
|
if name not in main.IRCPool.keys():
|
||||||
return dumps({"success": False, "reason": f"relay {num} not on {net}"})
|
return dumps({"success": False, "reason": f"relay {num} not on {net}"})
|
||||||
return dumps({"nickname": main.IRCPool[name].nickname})
|
return dumps({"nickname": main.IRCPool[name].nickname})
|
||||||
|
|
||||||
|
|
|
@ -384,6 +384,7 @@ def _initialList(net, num, listinfo, chanlimit):
|
||||||
|
|
||||||
# return (listinfo, mean, sigrelay, relay)
|
# return (listinfo, mean, sigrelay, relay)
|
||||||
|
|
||||||
|
|
||||||
def convert(data):
|
def convert(data):
|
||||||
"""
|
"""
|
||||||
Recursively convert a dictionary.
|
Recursively convert a dictionary.
|
||||||
|
@ -411,4 +412,3 @@ def initialList(net, num, listinfo, chanlimit):
|
||||||
See above docstring.
|
See above docstring.
|
||||||
"""
|
"""
|
||||||
deferToThread(_initialList, net, num, deepcopy(listinfo), chanlimit)
|
deferToThread(_initialList, net, num, deepcopy(listinfo), chanlimit)
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
from modules import provision
|
|
||||||
|
|
||||||
from twisted.internet import reactor
|
from twisted.internet import reactor
|
||||||
from twisted.internet.ssl import DefaultOpenSSLContextFactory
|
from twisted.internet.ssl import DefaultOpenSSLContextFactory
|
||||||
|
@ -8,8 +7,8 @@ import main
|
||||||
from core.bot import IRCBotFactory
|
from core.bot import IRCBotFactory
|
||||||
from modules import alias
|
from modules import alias
|
||||||
from modules.chankeep import nukeNetwork
|
from modules.chankeep import nukeNetwork
|
||||||
from modules.regproc import needToRegister
|
|
||||||
from modules.provision import provisionRelay
|
from modules.provision import provisionRelay
|
||||||
|
from modules.regproc import needToRegister
|
||||||
from utils.deliver_relay_commands import deliverRelayCommands
|
from utils.deliver_relay_commands import deliverRelayCommands
|
||||||
from utils.get import getRelay
|
from utils.get import getRelay
|
||||||
from utils.logging.log import log
|
from utils.logging.log import log
|
||||||
|
|
Loading…
Reference in New Issue