diff options
Diffstat (limited to 'bin-src/util/date.go')
-rw-r--r-- | bin-src/util/date.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/bin-src/util/date.go b/bin-src/util/date.go index 3b5c457..8599958 100644 --- a/bin-src/util/date.go +++ b/bin-src/util/date.go @@ -6,14 +6,17 @@ import ( ) func Date2HTML(t time.Time) template.HTML { + //nolint:gosec // false positive, trusted input return template.HTML(t.Local().Format("<time datetime=\"2006-01-02 15:04:05\" title=\"2006-01-02 15:04:05\">2006-01-02 <span class=time>15:04:05</span></time>")) } func DateTime2HTML(t time.Time) template.HTML { + //nolint:gosec // false positive, trusted input return template.HTML(t.Local().Format("<time datetime=\"2006-01-02 15:04:05\">2006-01-02 15:04:05</time>")) } func DateTime2ColorHTML(t time.Time) template.HTML { + //nolint:gosec // false positive, trusted input return template.HTML(t.Local().Format("<time class=daily datetime=\"2006-01-02 15:04:05\">2006-01-02 15:04:05</time>")) } |