mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-25 22:00:58 +02:00
Allow page.HasMenuCurrent() and node.HasMenuCurrent() to proceed with multi-level nested menus
Currently HasMenuCurrent only process the first 2 levels.
This commit is contained in:
committed by
Bjørn Erik Pedersen
parent
354192d2b8
commit
247574976c
@@ -626,6 +626,9 @@ func (p *Page) HasMenuCurrent(menu string, me *MenuEntry) bool {
|
||||
if child.IsEqual(m) {
|
||||
return true
|
||||
}
|
||||
if p.HasMenuCurrent(menu, child) {
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user