summaryrefslogtreecommitdiffstats
path: root/module/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'module/plugins')
-rw-r--r--module/plugins/Hook.py5
1 files changed, 4 insertions, 1 deletions
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)