From bae3c819ca0cc7d52a3b691a71c3bbe26458d3dd Mon Sep 17 00:00:00 2001 From: Luke Rogers Date: Sun, 10 Nov 2013 13:36:02 +1300 Subject: [PATCH] fixed singlethread --- core/loader.py | 1 - core/main.py | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/core/loader.py b/core/loader.py index 5111075..d042f60 100644 --- a/core/loader.py +++ b/core/loader.py @@ -90,7 +90,6 @@ class PluginLoader(object): for obj in namespace.itervalues(): if hasattr(obj, '_hook'): # check for magic if obj._thread: - # TODO: pretty sure this is broken self.bot.threads[obj] = main.Handler(self.bot, obj) for type, data in obj._hook: diff --git a/core/main.py b/core/main.py index 1cad6a3..7c69332 100755 --- a/core/main.py +++ b/core/main.py @@ -94,7 +94,7 @@ def do_sieve(sieve, bot, input, func, type, args): class Handler(object): """Runs plugins in their own threads (ensures order)""" - def __init__(self, func, bot): + def __init__(self, bot, func): self.func = func self.bot = bot self.input_queue = Queue.Queue()