zurb/foundation — pull request #4083 by aschepis (2014-01-07 12:55:31+00:00)
Title: fix issue where errors occur if data('index') is NaN

Ran into this issue while implementing a top nav in a single page application that loads the nav bar dynamically. I couldn't isolate exactly why data('index') ended up as NaN but i suspect that it had to do with the coming and going of the nav DOM (via backbone render function)

because this only occurred when the menu was toggling open after having been previously closed resetting data('index') to zero made sense.