From 55ceb9b581698471de7ea9c77843c08791ae2faa Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 10 Oct 2013 12:54:59 -0400 Subject: got delay calculation backwards --- Assistant/Threads/Cronner.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Assistant/Threads/Cronner.hs') diff --git a/Assistant/Threads/Cronner.hs b/Assistant/Threads/Cronner.hs index b683d2e47..a5fb2de7d 100644 --- a/Assistant/Threads/Cronner.hs +++ b/Assistant/Threads/Cronner.hs @@ -122,7 +122,7 @@ secondsUntilLocalTime :: LocalTime -> IO Seconds secondsUntilLocalTime t = do now <- getCurrentTime tz <- getTimeZone now - let secs = truncate $ diffUTCTime now (localTimeToUTC tz t) + let secs = truncate $ diffUTCTime (localTimeToUTC tz t) now return $ if secs > 0 then Seconds secs else Seconds 0 -- cgit v1.2.3