Some style consistency

* [Testing for falsiness](http://designpepper.com/blog/drips/truthy-and-falsy-values-in-javascript.html) is not considered to be very safe, so it is best to be explicit with `length` and write it as a truthy statement
* Other files declare the length attribute inside of the `for` loop, so to keep the style consistent, the `length` variable was removed, as it was only used inside of the `for` declaration