diff --git a/plugins/Gameknot.py b/plugins/Gameknot.py index 3c5e4b350..6e72a8b38 100644 --- a/plugins/Gameknot.py +++ b/plugins/Gameknot.py @@ -141,7 +141,7 @@ class Gameknot(callbacks.PrivmsgCommandAndRegexp): # Game is over. m = self._gkWon.search(s) winner = m.group(1) - m = self._gkReason.match(s) + m = self._gkReason.search(s) if m: reason = m.group(1) else: diff --git a/test/test_Gameknot.py b/test/test_Gameknot.py index 0e7d4dd58..96e06e5f2 100644 --- a/test/test_Gameknot.py +++ b/test/test_Gameknot.py @@ -48,6 +48,8 @@ class GameknotTestCase(PluginTestCase): def testSnarfer(self): self.assertRegexp('http://gameknot.com/chess.pl?bd=907498', '\x02ddipaolo\x02 won') + self.assertRegexp('http://gameknot.com/chess.pl?bd=907498', + '\x02chroniqueur\x02 resigned') self.assertRegexp('http://gameknot.com/chess.pl?bd=955432', '\x02ddipaolo\x02 lost')