mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-20 21:31:32 +02:00
@@ -95,6 +95,7 @@ type Site struct {
|
||||
language *langs.Language
|
||||
languagei int
|
||||
pageMap *pageMap
|
||||
store *maps.Scratch
|
||||
|
||||
// The owning container.
|
||||
h *HugoSites
|
||||
@@ -248,6 +249,7 @@ func NewHugoSites(cfg deps.DepsCfg) (*HugoSites, error) {
|
||||
language: language,
|
||||
languagei: i,
|
||||
frontmatterHandler: frontmatterHandler,
|
||||
store: maps.NewScratch(),
|
||||
}
|
||||
|
||||
if i == 0 {
|
||||
@@ -614,6 +616,10 @@ func (s *Site) AllRegularPages() page.Pages {
|
||||
return s.h.RegularPages()
|
||||
}
|
||||
|
||||
func (s *Site) Store() *maps.Scratch {
|
||||
return s.store
|
||||
}
|
||||
|
||||
func (s *Site) CheckReady() {
|
||||
if s.state != siteStateReady {
|
||||
panic("this method cannot be called before the site is fully initialized")
|
||||
|
Reference in New Issue
Block a user