summaryrefslogtreecommitdiffstats
path: root/module/PluginThread.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-10-13 15:42:44 +0200
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-10-13 15:42:44 +0200
commitefdd172e823cfc59d33c7acf30510cf05c2791fb (patch)
treeb977a715a9562e2288bf933921c28c20c94df347 /module/PluginThread.py
parentimprovement for hook plugins, new internal plugin type (diff)
downloadpyload-efdd172e823cfc59d33c7acf30510cf05c2791fb.tar.xz
fixes syntax error on old python versions
Diffstat (limited to 'module/PluginThread.py')
-rw-r--r--module/PluginThread.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/module/PluginThread.py b/module/PluginThread.py
index d29d609c7..aeb2ac2aa 100644
--- a/module/PluginThread.py
+++ b/module/PluginThread.py
@@ -454,8 +454,10 @@ class HookThread(PluginThread):
def run(self):
try:
try:
- self.f(*self.args, thread=self, **self.kwargs)
+ self.kwargs["thread"] = self
+ self.f(*self.args, **self.kwargs)
except TypeError:
+ del self.kwargs["thread"]
self.f(*self.args, **self.kwargs)
finally:
local = copy(self.active)