From 307e2f7ce58af0bd70fe4741da8c5dc4c1f82008 Mon Sep 17 00:00:00 2001 From: pb Date: Sun, 29 Nov 2009 16:55:45 +0000 Subject: git-svn-id: https://ssl.buetow.org/repos/hsbot/trunk@7 9f8f72e9-4bf4-416e-b76e-7d4203597157 --- HsBot.hs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/HsBot.hs b/HsBot.hs index 71b9c6a..aa3f812 100644 --- a/HsBot.hs +++ b/HsBot.hs @@ -32,14 +32,17 @@ instance Ord Karma where data Conf = Conf { line :: String, loggs :: [String], maxLoggs :: Int, users :: [User], karmas :: [Karma] } deriving (Show, Read) -data User = User { userName :: String, userPts :: Int } deriving (Show, Read) +data User = User { userName :: String, userPts :: Int } deriving (Show, Read) instance Eq User where x == y = (userPts x) == (userPts y) instance Ord User where x < y = (userPts x) < (userPts y) x > y = (userPts x) > (userPts y) - x >= y = not (x < y) + x >= y = not (maxLoggMessages :: Int +maxLoggMessages = 10 + +x < y) x <= y = not (x > y) class Render a where render :: a -> String -- cgit v1.2.3