Fix undefs
parent
85a396fb9c
commit
cee9239c22
|
@ -119,6 +119,7 @@ function walkTree(tree, visitor, context, options, path = '')
|
|||
// Process array, remembering keys and indices within series of elements of the same type
|
||||
let index = 0, series = 0;
|
||||
let lastType = null, lastHasKey = false;
|
||||
let res = [];
|
||||
for (let item of tree)
|
||||
{
|
||||
if (item)
|
||||
|
@ -174,7 +175,7 @@ function walkTree(tree, visitor, context, options, path = '')
|
|||
const Component = getType(tree);
|
||||
const visitChildren = (render, compInstance, elContext, childContext) =>
|
||||
{
|
||||
const result = visitor ? visitor(tree, compKey, compInstance, elContext, childContext) : true;
|
||||
const result = visitor ? visitor(tree, path, compInstance, elContext, childContext) : true;
|
||||
if (result !== false)
|
||||
{
|
||||
// A false wasn't returned so we will attempt to visit the children
|
||||
|
|
Loading…
Reference in New Issue