aboutsummaryrefslogtreecommitdiff
path: root/modules/random_number.py
diff options
context:
space:
mode:
authorGravatar jesopo2018-09-30 17:29:09 +0100
committerGravatar jesopo2018-09-30 17:29:09 +0100
commit10ef985a8a849a6bbfa8cbb63c2548e42ffb3957 (patch)
tree4da29ff0462ca69820d81aa95afb4b261ab3213c /modules/random_number.py
parentreceived.command takes a final [command] part (diff)
signature
Switch to using docstring for usage, permission and require_mode
Diffstat (limited to 'modules/random_number.py')
-rw-r--r--modules/random_number.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/random_number.py b/modules/random_number.py
index a8451d88..5fa25748 100644
--- a/modules/random_number.py
+++ b/modules/random_number.py
@@ -4,10 +4,11 @@ from src import ModuleManager, Utils
class Module(ModuleManager.BaseModule):
_name = "Random"
- @Utils.hook("received.command.random|rand", usage="[start] [end]")
+ @Utils.hook("received.command.random|rand")
def random(self, event):
"""
- Get a random number
+ :help: Get a random number
+ :usage: [start] [end]
"""
start, end = "1", "100"
if len(event["args_split"]) > 1:
@@ -30,6 +31,6 @@ class Module(ModuleManager.BaseModule):
@Utils.hook("received.command.guid")
def guid(self, event):
"""
- Get a random guid
+ :help: Get a random guid
"""
event["stdout"].write(str(uuid.uuid4()))