From 3453479235bec9ec61b3e9dd95aef66a78fe6296 Mon Sep 17 00:00:00 2001 From: jesopo Date: Wed, 19 Feb 2020 17:29:10 +0000 Subject: utilise @utils.export for function exporting in more places --- modules/badges.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'modules/badges.py') diff --git a/modules/badges.py b/modules/badges.py index 21531c7c..0fef164b 100644 --- a/modules/badges.py +++ b/modules/badges.py @@ -7,8 +7,7 @@ RE_HUMAN_FORMAT = re.compile(r"(\d\d\d\d)-(\d?\d)-(\d?\d)") HUMAN_FORMAT_HELP = "year-month-day (e.g. 2018-12-29)" class Module(ModuleManager.BaseModule): - def on_load(self): - self.exports.add("command-spec.marginstring", self._marginstring_spec) + @utils.export("command-spec.marginstring") def _marginstring_spec(self, server, channel, user, args): if len(args) > 1: new_args = args[:-1] -- cgit v1.3.1-10-gc9f91