summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Dessaux2011-09-19 00:37:56 +0200
committerJulien Dessaux2011-09-19 00:37:56 +0200
commit7e3cc4790afd795e3f488e0a37ce34797f07bc60 (patch)
treea719cd71e82cf2a176bdcd3d7a6382e40c11ef69
parentAdded quote delete. (diff)
downloadhsbot-7e3cc4790afd795e3f488e0a37ce34797f07bc60.tar.gz
hsbot-7e3cc4790afd795e3f488e0a37ce34797f07bc60.tar.bz2
hsbot-7e3cc4790afd795e3f488e0a37ce34797f07bc60.zip
Cosmetic.
-rw-r--r--Hsbot/Plugin/Quote.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Hsbot/Plugin/Quote.hs b/Hsbot/Plugin/Quote.hs
index baacb77..d849c22 100644
--- a/Hsbot/Plugin/Quote.hs
+++ b/Hsbot/Plugin/Quote.hs
@@ -99,7 +99,7 @@ setQuote :: QuoteID -> Quote -> Update QuoteDB ()
setQuote quoteId theQuote = get >>= \db -> put db { quoteBotDB = M.insert quoteId theQuote (quoteBotDB db) }
getLastActiveQuote :: IRC.Channel -> Query QuoteDB (Maybe QuoteID)
-getLastActiveQuote channel = asks lastActive >>= return . M.lookup channel
+getLastActiveQuote channel = fmap (M.lookup channel) (asks lastActive)
$(makeAcidic ''QuoteDB [ 'getQuote, 'getQuoteDB, 'isQuoteLockedFor, 'lockQuoteIdFor, 'deleteQuote, 'setQuote
, 'getLastActiveQuote ])