mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-31 18:32:11 +00:00
Fixes times.toSeconds to handle hours and minutes correctly.
This commit is contained in:
@@ -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
|
||||
|
||||
|
||||
Reference in New Issue
Block a user