commit 97e3d13e07feacf4077c3fec359754128ca59d9c
parent ec9f2c528eb5c8c9de8cc29967a80fb52a1de431
Author: Shimmy Xu <shimmy.xu@shimmy1996.com>
Date: Sat, 4 Jan 2020 22:16:26 -0600
Use string.HasSuffix
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/layouts/partials/list_comment.html b/layouts/partials/list_comment.html
@@ -5,7 +5,7 @@
<hr/>
<div id="{{ $hash }}">
<b>{{ or .name (i18n "hyperskip-name-default") }}</b>
- {{- if eq (.email_hash | last 10) ($.Site.Author.email | sha256 | last 10) -}}
+ {{- if (strings.HasSuffix ($.Site.Author.email | sha256) .email_hash) -}}
✦
{{- else -}}
<code>{{ .email_hash | last 10 }}</code>