Eric Bower
·
03 Aug 22
util.go
1package db
2
3import "strings"
4
5func FilterMetaFiles(posts []*Post) []*Post {
6 filtered := []*Post{}
7 for _, post := range posts {
8 if strings.HasPrefix(post.Filename, "_") {
9 continue
10 }
11 filtered = append(filtered, post)
12 }
13 return filtered
14}