Only set parentpage if a subpage was found

Fixes error if there's no header or footer
This commit is contained in:
kristi
2012-05-22 11:55:02 -07:00
parent 97dd1b3b00
commit 5f5187e05c
+3 -2
View File
@@ -435,8 +435,9 @@ module Gollum
dirs.pop
end
page = find_page_in_tree(map, name, '')
page.parent_page = self
if page = find_page_in_tree(map, name, '')
page.parent_page = self
end
page
end