aboutsummaryrefslogtreecommitdiff
path: root/templates/status.tmpl
diff options
context:
space:
mode:
authorr <r@freesoftwareextremist.com>2020-02-19 16:33:21 +0000
committerr <r@freesoftwareextremist.com>2020-02-19 16:33:21 +0000
commitdd23ac48678c704949074dd0e41bb8a3550cc33f (patch)
tree923248c707bcf17db9a7b921195933c3c828935c /templates/status.tmpl
parentfe31d4197b66cced9ca84779fac4fe69242d844b (diff)
downloadbloat-dd23ac48678c704949074dd0e41bb8a3550cc33f.tar.gz
bloat-dd23ac48678c704949074dd0e41bb8a3550cc33f.zip
Fix time duration value
- Make sure that duration is not < 0 - Handle nil ExpiresAt time in poll
Diffstat (limited to 'templates/status.tmpl')
-rw-r--r--templates/status.tmpl2
1 files changed, 1 insertions, 1 deletions
diff --git a/templates/status.tmpl b/templates/status.tmpl
index c4f2e5f..536f515 100644
--- a/templates/status.tmpl
+++ b/templates/status.tmpl
@@ -126,7 +126,7 @@
<span>{{.Poll.VotesCount}} votes</span>
{{if .Poll.Expired}}
<span> - poll expired </span>
- {{else}}
+ {{else if .Poll.ExpiresAt}}
<span>
- poll ends in
<time datetime="{{FormatTimeRFC3339 .Poll.ExpiresAt}}" title="{{FormatTimeRFC822 .Poll.ExpiresAt}}">