From 24b99d7d1ee90a1f0add35afa2f42547723d5cf1 Mon Sep 17 00:00:00 2001 From: Caleb Gardner Date: Wed, 5 Feb 2025 05:40:10 -0600 Subject: [PATCH] lowercase blog ids --- internal/blog/blog.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/blog/blog.go b/internal/blog/blog.go index 88980d3..a201358 100644 --- a/internal/blog/blog.go +++ b/internal/blog/blog.go @@ -63,7 +63,7 @@ func (b *Blog) HTMX(blogApp *BlogApp, ctx context.Context) string { func (b Blog) IDFromTitle() string { id := strings.Join(regexp.MustCompile("([A-z]| |[0-9])*").FindAllString(b.Title, -1), "") - return strings.ReplaceAll(id, " ", "-") + return strings.ToLower(strings.ReplaceAll(id, " ", "-")) } func (b *BlogApp) ConvertBlog(blog *Blog) {