Fix cache reset for a page's collections on server live reload

Fixes #7085
This commit is contained in:
Bjørn Erik Pedersen
2020-03-22 13:42:39 +01:00
parent 244e49c0ea
commit cfa73050a4
3 changed files with 8 additions and 1 deletions

View File

@@ -1492,6 +1492,9 @@ func (s *Site) resetBuildState(sourceChanged bool) {
s.PageCollections = newPageCollections(s.pageMap)
s.pageMap.withEveryBundlePage(func(p *pageState) bool {
p.pagePages = &pagePages{}
if p.bucket != nil {
p.bucket.pagesMapBucketPages = &pagesMapBucketPages{}
}
p.parent = nil
p.Scratcher = maps.NewScratcher()
return false