From 38485e206ab503cf0f755418177511412d0d2bd5 Mon Sep 17 00:00:00 2001 From: James Scott Date: Thu, 13 Dec 2012 20:12:51 -0500 Subject: [PATCH] Fixed the start game command --- plugin.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugin.py b/plugin.py index 4cbf2f6..6429b25 100644 --- a/plugin.py +++ b/plugin.py @@ -134,11 +134,15 @@ class Cah(callbacks.Plugin): irc.reply("Game not running.") - def cah(self, irc, msg, numrounds=5): + def cah(self, irc, msg, args): """Starts a cards against humanity game, takes an optional arguement of number of rounds""" channel = ircutils.toLower(msg.args[0]) #TODO: this is prob needs fixing. + if len(arg) < 1: + numrounds = 5 + else: + numrounds = args[0] try: irc.reply("A game is running, please wait till it is finished to start a new one.") except: