fix jsHint errors in branch 2.0.0

`i` is a string.