From d037aec415c79c8778b1c81d11ff3442e262895a Mon Sep 17 00:00:00 2001 From: Grzegorz Adam Hankiewicz Date: Sun, 17 Nov 2013 21:31:05 +0100 Subject: Fixes times.toSeconds to handle hours and minutes correctly. --- lib/pure/times.nim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/pure/times.nim b/lib/pure/times.nim index 80a5ad8d3..e967ef683 100644 --- a/lib/pure/times.nim +++ b/lib/pure/times.nim @@ -246,7 +246,8 @@ proc toSeconds(a: TTimeInfo, interval: TTimeInterval): float = else: curMonth.inc() result += float(newinterv.days * 24 * 60 * 60) - result += float(newinterv.minutes * 60 * 60) + result += float(newinterv.hours * 60 * 60) + result += float(newinterv.minutes * 60) result += float(newinterv.seconds) result += newinterv.miliseconds / 1000 -- cgit 1.4.1-2-gfad0