Commits

Dafydd Francis  committed 09a08f3

Fixed the odd bug when the search module was returning more than one message

  • Participants
  • Parent commits f4a431e

Comments (0)

Files changed (1)

File modules/search.py

     message = msg.replace("!g", "", 1).strip()
     result = first_result(message)
     tbot.msg(channel, "%s: %s" % (user, result.encode("utf-8")))
-g.rule = '^!g'
+g.rule = '^!g '
 
 def gc(tbot, user, channel, msg):
     message = msg.replace("!gc", "", 1).strip()
-    result = first_result(message)
+    result = count_results(message)
     tbot.msg(channel, "%s: %s" % (user, result.encode("utf-8")))
-gc.rule = '^!gc'
+gc.rule = '^!gc '
 
 def gfight(tbot, user, channel, msg):
     regex = re.compile('TwistedBot: (.*?) vs (.*)')