shutterstock / rickshaw

JavaScript toolkit for creating interactive real-time graphs
https://shutterstock.github.io/rickshaw
MIT License
6.53k stars 941 forks source link

hoverDetail has infinite loop bug #96

Closed bnormoyle closed 12 years ago

bnormoyle commented 12 years ago

In Rickshaw.Graph.HoverDetail.js, in the loop from lines 62 to 73, it will loop infinitely if domainX is a value in stackedData[0] and approximateIndex is an index to the left of its position. Instead of incrementing the index to domainX's position in the list, the final check will fail as it is < and not <=, and it will decrement instead, continually bouncing between the two indices to the left of domainX's position in the list. I have an example available if need be.

dchester commented 12 years ago

Thanks -- fixed with 2fee4cef23498656443063d9d6b256306fa95542.

bohan commented 11 years ago

COOL TNX FOR THE FIX