hugo

Unnamed repository; edit this file 'description' to name the repository.

git clone git://git.shimmy1996.com/hugo.git
commit a7555c54310612a746d34361a2d58f62207349bb
parent c265c102ae0705011bca6999e5b1c14fb00fa859
Author: Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Date:   Thu, 17 Aug 2017 08:32:47 +0200

hugolib: Do not return error in Eq on type mismatch

Diffstat:
Mhugolib/site_sections.go | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hugolib/site_sections.go b/hugolib/site_sections.go
@@ -115,7 +115,8 @@ func (p *Page) IsAncestor(other interface{}) (bool, error) {
 func (p *Page) Eq(other interface{}) (bool, error) {
 	pp, err := unwrapPage(other)
 	if err != nil {
-		return false, err
+		// Do not return an error on type mismatch.
+		return false, nil
 	}
 
 	return p == pp, nil