Skip to content
Permalink
Browse files

hugolib: Fix .Sections vs siblings

Fixes #6365
  • Loading branch information
bep committed Nov 26, 2019
1 parent 96f0965 commit da53523599b43261520a22d77019b390aaa072e7
Showing with 2 additions and 2 deletions.
  1. +0 −2 hugolib/pages_map.go
  2. +2 −0 hugolib/site_sections_test.go
@@ -176,8 +176,6 @@ func (m *pagesMap) addPage(p *pageState) {
}

bucket = v.(*pagesMapBucket)
p.bucket = bucket

bucket.pages = append(bucket.pages, p)
}

@@ -321,6 +321,8 @@ PAG|{{ .Title }}|{{ $sect.InSection . }}
rootPage := s.getPage(page.KindPage, "mypage.md")
c.Assert(rootPage, qt.Not(qt.IsNil))
c.Assert(rootPage.Parent().IsHome(), qt.Equals, true)
// https://github.com/gohugoio/hugo/issues/6365
c.Assert(rootPage.Sections(), qt.HasLen, 0)

// Add a odd test for this as this looks a little bit off, but I'm not in the mood
// to think too hard a out this right now. It works, but people will have to spell

0 comments on commit da53523

Please sign in to comment.
You can’t perform that action at this time.