summaryrefslogtreecommitdiff
path: root/lib/Postdelay
diff options
context:
space:
mode:
authorGregor Kleen <aethoago@141.li>2017-02-20 20:47:31 +0100
committerGregor Kleen <aethoago@141.li>2017-02-20 20:47:31 +0100
commitee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a (patch)
tree3d6a5f09c9c3ff5504b97ba69dd4689dc7ce0587 /lib/Postdelay
parent479d66dd0b3c2b6919e626b1c3c3fea9b0c9df8a (diff)
downloadpostdelay-ee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a.tar
postdelay-ee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a.tar.gz
postdelay-ee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a.tar.bz2
postdelay-ee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a.tar.xz
postdelay-ee87f8d3ecc2d23584e378bfd3160ba6f49ebf4a.zip
Minor cleanup
Diffstat (limited to 'lib/Postdelay')
-rw-r--r--lib/Postdelay/TimeSpec.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Postdelay/TimeSpec.hs b/lib/Postdelay/TimeSpec.hs
index 9361057..454f704 100644
--- a/lib/Postdelay/TimeSpec.hs
+++ b/lib/Postdelay/TimeSpec.hs
@@ -145,8 +145,8 @@ offsets reqSgn = fmap (foldMap . review $ prioEndo' Offset) $ (:) <$> offset req
145 asOffset :: Time -> Endo LocalTime 145 asOffset :: Time -> Endo LocalTime
146 asOffset by = Endo $ flexDT.seconds' %~ (^+^ by) 146 asOffset by = Endo $ flexDT.seconds' %~ (^+^ by)
147 offset :: Bool -> m (Endo LocalTime) 147 offset :: Bool -> m (Endo LocalTime)
148 offset sgnReq@(bool optSigned signed -> sgn) 148 offset (bool (optSigned, "Time offset") (signed, "Signed time offset") -> (sgn, desc))
149 = asOffset <$> lexeme (sgn timeLength) <?> if sgnReq then "Signed time offset" else "Time offset" 149 = asOffset <$> lexeme (sgn timeLength) <?> desc
150 150
151timeZone :: (StringParser s m, MonadIO m) => m (Either TimeZone TZ) 151timeZone :: (StringParser s m, MonadIO m) => m (Either TimeZone TZ)
152timeZone = label "Timezone" $ (Left <$> numericTimezone) <|> (Right <$> namedTimezone) 152timeZone = label "Timezone" $ (Left <$> numericTimezone) <|> (Right <$> namedTimezone)