Skip to content

Commit

Permalink
templates: remove unused method
Browse files Browse the repository at this point in the history
  • Loading branch information
Wessie committed Feb 21, 2024
1 parent 2462b19 commit f7630ac
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions templates/loader.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,25 +150,6 @@ func (s *Site) ResolveThemeName(name string) string {
return DEFAULT_DIR
}

func (s *Site) makeCache() error {
const op errors.Op = "templates/makeCache"

cache := make(map[string]*template.Template)
for themeName, theme := range s.themes {
for name, bundle := range theme.pages {
key := themeName + "/" + name
tmpl, err := bundle.Template()
if err != nil {
return errors.E(op, err)
}
cache[key] = tmpl
}
}

s.cache = cache
return nil
}

func FromDirectory(dir string) (*Site, error) {
const op errors.Op = "templates/FromDirectory"

Expand Down

0 comments on commit f7630ac

Please sign in to comment.