Merge pull request #1465 from thomasritz/fix-wrong-parent
Fixes computation of `parent`.
This commit is contained in:
commit
fbe71f51e4
|
@ -9,7 +9,9 @@ module Middleman
|
|||
tail = parts.pop
|
||||
is_index = (tail == app.index_file)
|
||||
|
||||
return nil if is_index && parts.length < 1
|
||||
if parts.empty?
|
||||
return is_index ? nil : store.find_resource_by_path(app.index_file)
|
||||
end
|
||||
|
||||
test_expr = parts.join('\\/')
|
||||
# A makeshift for eponymous reverse-lookup
|
||||
|
|
Loading…
Reference in a new issue