From 1fe30eb95bc3219a5c16b90d443f8268cc85456c Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Sat, 5 Apr 2025 23:24:12 +0800 Subject: Export functions intended to be used in HTML templates --- resources.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'resources.go') diff --git a/resources.go b/resources.go index 0f2e1a9..637b8ed 100644 --- a/resources.go +++ b/resources.go @@ -32,11 +32,11 @@ func loadTemplates() (err error) { minifier.Add("text/html", &minifierOptions) templates = template.New("templates").Funcs(template.FuncMap{ - "first_line": firstLine, - "path_escape": pathEscape, - "query_escape": queryEscape, - "dereference_error": dereferenceOrZero[error], - "minus": minus, + "first_line": FirstLine, + "path_escape": PathEscape, + "query_escape": QueryEscape, + "dereference_error": DereferenceOrZero[error], + "minus": Minus, }) err = fs.WalkDir(embeddedResourcesFS, "templates", func(path string, d fs.DirEntry, err error) error { -- cgit v1.2.3