From 3be34eb4b5b286f02de780ce34a7691d49c7a384 Mon Sep 17 00:00:00 2001 From: spoob Date: Wed, 13 Jan 2010 11:21:11 +0100 Subject: forgot changes --- module/plugins/Hook.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'module/plugins/Hook.py') diff --git a/module/plugins/Hook.py b/module/plugins/Hook.py index 366cde185..6f8a48802 100644 --- a/module/plugins/Hook.py +++ b/module/plugins/Hook.py @@ -40,7 +40,10 @@ class Hook(): def readConfig(self): self.configParser.loadData() section = self.props['name'] - self.config = self.configParser.getConfig()[section] + try: + self.config = self.configParser.getConfig()[section] + except: + self.setup() def setup(self): self.configParser.set(self.props["name"], {"option": "activated", "type": "bool", "name": "Activated"}, True) -- cgit v1.2.3