content: switch static file copying to an allowlist
1 file changed, 5 insertions(+), 4 deletions(-)
changed files
M domain/content/posts.go → domain/content/posts.go
@@ -66,9 +66,10 @@ pageURLReplacer = strings.NewReplacer( "index.md", "", ".md", "", ) - SkipList = []string{ - "LICENSE", - "taplo.toml", + StaticList = []string{ + "config.toml", + "cv.html", + "public_key.asc", } )@@ -165,7 +166,7 @@ return err } cc.Pages = append(cc.Pages, page) } - } else if !slices.Contains(SkipList, filename) { + } else if slices.Contains(StaticList, filename) { cc.StaticFiles = append(cc.StaticFiles, filename) } }