From 09b1ee2f07a0e064ba7ea5446aeaabefc07c8f97 Mon Sep 17 00:00:00 2001 From: moneromooo Date: Sat, 10 Jan 2015 14:03:07 +0000 Subject: [PATCH] Fix rainactive synopsis, and error on usage when missing amount/hours --- tipbot/modules/tipping.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tipbot/modules/tipping.py b/tipbot/modules/tipping.py index bb5d3ed..6e1aa9a 100644 --- a/tipbot/modules/tipping.py +++ b/tipbot/modules/tipping.py @@ -161,6 +161,9 @@ def RainActive(nick,chan,cmd): if chan[0] != '#': SendTo(nick, "Raining can only be done in a channel") return + if not amount or not hours: + SendTo(chan, "usage: !rainactive []") + return try: amount=float(amount) if amount <= 0: @@ -285,7 +288,7 @@ RegisterCommand({ RegisterCommand({ 'module': __name__, 'name': 'rainactive', - 'parms': ' []', + 'parms': ' []', 'function': RainActive, 'registered': True, 'help': "rain some coins on whoever was active recently"