summaryrefslogtreecommitdiffstats
path: root/module
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2013-07-11 16:53:43 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2013-07-11 16:53:43 +0200
commit64563ae494fc63dda57949487a3011b8eeb0456f (patch)
tree191d35afba25440f292a44dc974e22964741761c /module
parentVersion 1.08: fixes and cosmetics (diff)
downloadpyload-64563ae494fc63dda57949487a3011b8eeb0456f.tar.xz
Version 1.09: code cosmetics
Diffstat (limited to 'module')
-rw-r--r--module/plugins/hooks/DeleteFinished.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/module/plugins/hooks/DeleteFinished.py b/module/plugins/hooks/DeleteFinished.py
index c03298b2c..155158701 100644
--- a/module/plugins/hooks/DeleteFinished.py
+++ b/module/plugins/hooks/DeleteFinished.py
@@ -23,7 +23,7 @@ from module.plugins.Hook import Hook
class DeleteFinished(Hook):
__name__ = 'DeleteFinished'
- __version__ = '1.08'
+ __version__ = '1.09'
__description__ = 'Automatically delete all finished packages from queue'
__config__ = [
('activated', 'bool', 'Activated', 'False'),
@@ -71,13 +71,14 @@ class DeleteFinished(Hook):
## event managing ##
def addEvent(self, event, func):
'''Adds an event listener for event name'''
- if event in self.manager.events:
- if func in self.manager.events[event]:
+ if event in self.m.events:
+ if func in self.m.events[event]:
self.logDebug('Function already registered %s' % func)
else:
- self.manager.events[event].append(func)
+ self.m.events[event].append(func)
else:
- self.manager.events[event] = [func]
+ self.m.events[event] = [func]
def setup(self):
- self.removeEvent = self.manager.removeEvent
+ self.m = self.manager
+ self.removeEvent = self.m.removeEvent