// Check if key fields match - if not, we need to replace from this point
if (this._hasKeyMismatch(childEntries, prevItem, currItem)) {
const newItems = currArr.slice(i);
entries.push({ kind: EntryKind.Push, k: path.slice(), v: newItems.length > 0 ? newItems : undefined, i });
return;
}
// Keys match, recurse into the object