From 482161e98b254c4d67a81def8c726dad7bf03af8 Mon Sep 17 00:00:00 2001 From: Steve Vaught Date: Tue, 19 Apr 2011 00:50:58 -0400 Subject: Added error checking for empty parameters --- modules/search.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'modules/search.py') diff --git a/modules/search.py b/modules/search.py index 1067531..d83a47e 100755 --- a/modules/search.py +++ b/modules/search.py @@ -69,6 +69,8 @@ r_query = re.compile( ) def gcs(phenny, input): + if not input.group(2): + return phenny.reply("Nothing to compare.") queries = r_query.findall(input.group(2)) if len(queries) > 6: return phenny.reply('Sorry, can only compare up to six things.') -- cgit v1.2.3-1-g7c22