Fix number of hours in human-readable duration
The number of hours in human-readable duration is calculated wrongly. Closes #1878.
This commit is contained in:
parent
5ce2dcec09
commit
a0e00986d7
1 changed files with 1 additions and 1 deletions
|
|
@ -38,7 +38,7 @@ Rectangle {
|
|||
var totalSeconds = Math.floor(duration / 1000);
|
||||
var seconds = totalSeconds % 60;
|
||||
var minutes = (Math.floor(totalSeconds / 60)) % 60;
|
||||
var hours = (Math.floor(totalSeconds / (60 * 24))) % 24;
|
||||
var hours = (Math.floor(totalSeconds / (60 * 60))) % 24;
|
||||
// Always show minutes and don't prepend zero into the leftmost element
|
||||
var ss = maybeZeroPrepend(seconds);
|
||||
var mm = (hours > 0) ? maybeZeroPrepend(minutes) : minutes.toString();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue