Return early from appendThemeTemplates

This commit is contained in:
Bjørn Erik Pedersen 2016-03-17 23:36:11 +01:00
parent c50c66879d
commit 3529152efe

View file

@ -1448,7 +1448,10 @@ func errorCollator(results <-chan error, errs chan<- error) {
}
func (s *Site) appendThemeTemplates(in []string) []string {
if s.hasTheme() {
if !s.hasTheme() {
return in
}
out := []string{}
// First place all non internal templates
for _, t := range in {
@ -1471,8 +1474,7 @@ func (s *Site) appendThemeTemplates(in []string) []string {
}
}
return out
}
return in
}
type taxRenderInfo struct {