summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--Plugins/Monitors/Weather.hs5
1 files changed, 3 insertions, 2 deletions
diff --git a/Plugins/Monitors/Weather.hs b/Plugins/Monitors/Weather.hs
index 38577bc..e166b74 100644
--- a/Plugins/Monitors/Weather.hs
+++ b/Plugins/Monitors/Weather.hs
@@ -71,9 +71,10 @@ pTime = do y <- getNumbersAsString
return (y, m, d ,([h]++[hh]++":"++[mi]++mimi))
pTemp :: Parser (Int, Int)
-pTemp = do f <- manyTill (digit <|> char '.') $ char ' '
+pTemp = do let num = digit <|> char '-' <|> char '.'
+ f <- manyTill num $ char ' '
manyTill anyChar $ char '('
- c <- manyTill digit $ (char ' ' <|> char '.')
+ c <- manyTill num $ char ' '
skipRestOfLine
return $ (floor (read c :: Double), floor (read f :: Double))