diff options
-rw-r--r-- | internal/misc/trivial.go (renamed from http_template_funcs.go) | 2 | ||||
-rw-r--r-- | resources.go | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/http_template_funcs.go b/internal/misc/trivial.go index 11e4fad..e59c17e 100644 --- a/http_template_funcs.go +++ b/internal/misc/trivial.go @@ -1,7 +1,7 @@ // SPDX-License-Identifier: AGPL-3.0-only // SPDX-FileCopyrightText: Copyright (c) 2025 Runxi Yu <https://runxiyu.org> -package forge +package misc import ( "net/url" diff --git a/resources.go b/resources.go index 637b8ed..e2168a3 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": misc.FirstLine, + "path_escape": misc.PathEscape, + "query_escape": misc.QueryEscape, + "dereference_error": misc.DereferenceOrZero[error], + "minus": misc.Minus, }) err = fs.WalkDir(embeddedResourcesFS, "templates", func(path string, d fs.DirEntry, err error) error { |