bugfix: dashboard shows ago when less then 1minute

This commit is contained in:
billybonks 2024-02-07 16:34:00 +08:00 committed by Christopher Charbonneau Wells
parent 59e9263a69
commit 5ccca11b42
1 changed files with 1 additions and 1 deletions

View File

@ -38,7 +38,7 @@ def duration_string(duration, precision="s"):
duration = ""
if h > 0:
duration = ngettext("%(hours)s hour", "%(hours)s hours", h) % {"hours": h}
if m > 0 and precision != "h":
if m >= 0 and precision != "h":
if duration != "":
duration += ", "
duration += ngettext("%(minutes)s minute", "%(minutes)s minutes", m) % {