mirror of
https://github.com/gohugoio/hugo.git
synced 2024-05-11 05:54:58 +00:00
Revert "Make Urls in menus respect CanonifyUrls"
This reverts commit 3ccb397902
.
This commit is contained in:
@@ -38,7 +38,7 @@ func (n *Node) Now() time.Time {
|
||||
|
||||
func (n *Node) HasMenuCurrent(menuId string, inme *MenuEntry) bool {
|
||||
if inme.HasChildren() {
|
||||
me := MenuEntry{Name: n.Title, Url: n.Url}
|
||||
me := MenuEntry{Name: n.Title, Url: string(n.Permalink)}
|
||||
|
||||
for _, child := range inme.Children {
|
||||
if me.IsSameResource(child) {
|
||||
@@ -52,7 +52,8 @@ func (n *Node) HasMenuCurrent(menuId string, inme *MenuEntry) bool {
|
||||
|
||||
func (n *Node) IsMenuCurrent(menuId string, inme *MenuEntry) bool {
|
||||
|
||||
me := MenuEntry{Name: n.Title, Url: n.Url}
|
||||
me := MenuEntry{Name: n.Title, Url: string(n.Permalink)}
|
||||
|
||||
if !me.IsSameResource(inme) {
|
||||
return false
|
||||
}
|
||||
|
Reference in New Issue
Block a user