documentcloud/underscore — pull request #1073 by gushov (2013-04-15 14:57:15+00:00)
Title: _.each treats any object with a length property as an array

Give the following code:
```javascript
var box = {
length: 2,
width: 2,
height: 2
};

_.each(box, function (value, prop) {
console.log(prop, value);
});
```
The expected result would be output would be:
```
length 2
width 2
height 2
```
The actual output is:
```
0 undefined
1 undefined
```
Instead of checking the existence of the length property I check that length - 1 is a property of the object. So Arrays and array-like things are treated as arrays and objects with a length property are treated as objects.