summaryrefslogtreecommitdiffhomepage
path: root/hugolib/page.go
diff options
context:
space:
mode:
authorCarl Johnson <[email protected]>2020-03-20 09:35:41 -0400
committerGitHub <[email protected]>2020-03-20 14:35:41 +0100
commit95f492114e33fc6e4d9dcfd2b7c1eca5c50d755f (patch)
tree1bcbfdd901a99eb712740d262128deb87ff6b31f /hugolib/page.go
parentc947351d7c4273b24663a56d8f32c8c011e9841f (diff)
downloadhugo-95f492114e33fc6e4d9dcfd2b7c1eca5c50d755f.tar.gz
hugo-95f492114e33fc6e4d9dcfd2b7c1eca5c50d755f.zip
Fix GetTerms nil pointer
Fixes #7061
Diffstat (limited to 'hugolib/page.go')
-rw-r--r--hugolib/page.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/hugolib/page.go b/hugolib/page.go
index 16c320ecd..f71c4d9b8 100644
--- a/hugolib/page.go
+++ b/hugolib/page.go
@@ -141,7 +141,7 @@ func (p *pageState) GetTerms(taxonomy string) page.Pages {
if p.IsHome() {
// TODO(bep) make this less magical, see taxonomyEntries.Insert.
self = "/" + page.KindHome
- } else {
+ } else if p.treeRef != nil {
self = p.treeRef.key
}