aboutsummaryrefslogtreecommitdiff
path: root/modules/auto_mode.py
diff options
context:
space:
mode:
authorGravatar jesopo2018-09-27 12:08:07 +0100
committerGravatar jesopo2018-09-27 12:08:07 +0100
commit6eb8b1ba6d9aaaf7df42f3d705149f02b6a1b871 (patch)
treeece91b1c4d871d5d2b9a3f6319598e33aa13f93f /modules/auto_mode.py
parentUse ModuleManager.BaseModule in more modules (diff)
signature
Move all exports to @Utils.export calls
Diffstat (limited to 'modules/auto_mode.py')
-rw-r--r--modules/auto_mode.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/modules/auto_mode.py b/modules/auto_mode.py
index 08648ca3..d1851a58 100644
--- a/modules/auto_mode.py
+++ b/modules/auto_mode.py
@@ -1,11 +1,9 @@
-from src import Utils
+from src import ModuleManager, Utils
-class Module(object):
+@Utils.export("channelset", {"setting": "automode",
+ "help": "Disable/Enable automode", "validate": Utils.bool_or_none})
+class Module(ModuleManager.BaseModule):
_name = "AutoMode"
- def __init__(self, bot, events, exports):
- exports.add("channelset", {"setting": "automode",
- "help": "Disable/Enable automode",
- "validate": Utils.bool_or_none})
def _check_modes(self, channel, user):
identified_account = user.get_identified_account()