From fbe0faa1aa0b78801bf71647a65cc5ba0fe6f00c Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Thu, 9 Oct 2008 07:07:48 +0000 Subject: [PATCH] slightly simplify time arithmetic --- Ledger/TimeLog.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Ledger/TimeLog.hs b/Ledger/TimeLog.hs index 7c51f5855..7d2b340a2 100644 --- a/Ledger/TimeLog.hs +++ b/Ledger/TimeLog.hs @@ -56,7 +56,7 @@ entryFromTimeLogInOut i o = outdate = showDateFrom outtime intime = parsedatetime $ tldatetime i outtime = parsedatetime $ tldatetime o - hours = fromRational (toRational (diffUTCTime outtime intime) / 3600) -- whatever.. + hours = realToFrac (diffUTCTime outtime intime) / 3600 amount = Amount (getcurrency "h") hours 1 txns = [RawTransaction acctname amount "", RawTransaction "assets:TIME" (-amount) ""]