You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The result of the last call should contain 2 objects, but it returns only one of them.
After digging a bit, I found out the in Node.js endPointSearch function calculates the index where 55 should be inserted.
index = this.ends.firstPositionOf({
end: val
});
The returned value is -1. So this code returns the last item in the list:
return this.ends.slice(index);
Can you please look into this?
Thanks,
Levon
The text was updated successfully, but these errors were encountered:
Hello,
Please see the code below to find the issue that I have faced.
var itree = new IntervalTree(10);
itree.add(50, 80, 'foo');
itree.add(44, 199, 'bar');
itree.pointSearch(55);
The result of the last call should contain 2 objects, but it returns only one of them.
After digging a bit, I found out the in Node.js endPointSearch function calculates the index where 55 should be inserted.
index = this.ends.firstPositionOf({
end: val
});
The returned value is -1. So this code returns the last item in the list:
return this.ends.slice(index);
Can you please look into this?
Thanks,
Levon
The text was updated successfully, but these errors were encountered: