flounder

A simple gemini site builder
Log | Files | Refs | README | LICENSE

commit b149f8c51be768716b4fb0c2db10ee6e685a0c06
parent a6c4ff2be3076c8747909dad18d29d37f8d0caab
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Thu, 18 Nov 2021 20:33:19 -0800

fix url encoding

should use %20 intsead of ' '

Diffstat:
Mgemini.go | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gemini.go b/gemini.go @@ -125,7 +125,7 @@ func runGeminiServer() { gt = template.New("main").Funcs(template.FuncMap{ "urlencode": func(s string) string { // Only need to escape spaces to make gemini links not break - return strings.Replace(s, " ", "+", -1) + return strings.Replace(s, " ", "%20", -1) }, }) gt, err = gt.ParseGlob(path.Join(c.TemplatesDirectory, "*.gmi"))