diff options
-rw-r--r-- | src/Main.hs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/Main.hs b/src/Main.hs index 40991681391f..fb1cf07a5d39 100644 --- a/src/Main.hs +++ b/src/Main.hs @@ -108,8 +108,7 @@ stripResult (Error s) = error $ "JSON error: " ++ s getMonthCount :: Int -> Int -> ServerPart Int getMonthCount y m = do count <- queryDB "countDE" $ makeQuery startkey endkey - let x = map (stripResult . fromJSON . snd) count - return $ stripCount x + return . stripCount $ map (stripResult . fromJSON . snd) count where startkey = JSArray [toJSON ("count" :: String), toJSON y, toJSON m] endkey = JSArray [toJSON ("count" :: String), toJSON y, toJSON m, JSObject (toJSObject [] )] |