1
0
mirror of https://github.com/gohugoio/hugo.git synced 2024-05-11 05:54:58 +00:00

Revert "Throw a noisy error when a post has no layout"

We have to figure out another way. There are perfectly valid reasons not having a layout for a page (I have have some broken sites as result of this).

See #1313

This reverts commit b15934008fd6a1e7bcf9b8a47ab66e33271c4dca.
This commit is contained in:
Bjørn Erik Pedersen
2016-07-14 11:29:21 +02:00
parent 318558f26c
commit ef9b915680

View File

@ -2025,7 +2025,7 @@ func (s *Site) renderAndWritePage(name string, dest string, d interface{}, layou
func (s *Site) render(name string, d interface{}, w io.Writer, layouts ...string) error { func (s *Site) render(name string, d interface{}, w io.Writer, layouts ...string) error {
layout, found := s.findFirstLayout(layouts...) layout, found := s.findFirstLayout(layouts...)
if found == false { if found == false {
jww.ERROR.Printf("Unable to locate layout for %s: %s\n", name, layouts) jww.WARN.Printf("Unable to locate layout for %s: %s\n", name, layouts)
return nil return nil
} }