From 7c9f31da0996c93c7baf60fb27d21940571e4122 Mon Sep 17 00:00:00 2001 From: Xe Iaso Date: Wed, 22 Feb 2023 15:36:26 +0000 Subject: [PATCH] cmd/web: hide your profile pic if you authored the active paste Closes #3 Signed-off-by: Xe Iaso --- cmd/web/tmpl/showpaste.tmpl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cmd/web/tmpl/showpaste.tmpl b/cmd/web/tmpl/showpaste.tmpl index 056c3c0..6e30ebe 100644 --- a/cmd/web/tmpl/showpaste.tmpl +++ b/cmd/web/tmpl/showpaste.tmpl @@ -1,6 +1,12 @@ {{template "header" .}} +{{if .UserInfo}} +{{if ne .PasterUserID .UserID}}
{{.PasterDisplayName}}
+{{end}} +{{else}} +
{{.PasterDisplayName}}
+{{end}}

Created at {{.CreatedAt}}

@@ -8,4 +14,5 @@ Permalink - Download - Raw{{if eq .UserID .PasterUserID}} - Delete{{end}} + {{template "footer" .}}