tabs and spaces were mixed in this file. changed to all spaces.
change new Array() to more idiomatic [] which is used elsewhere in the code base
add missing semi-colon
do not create functions inside of loops as JS will create the function anew each time rather than reusing the function object
var should only be called on a variable once within a function
different implementations behave differently when a radix is omitted, so always specify a radix in parseInt()
Merge pull request #350 from Trott/minor-cleanup

JS file cleanup