Don't die when user adds enumerable properties to Array.prototype

I was wondering why [Joi](https://github.com/spumko/joi) was failing randomly in some code I was working on, and then I found this hidden away in the depths:

```javascript
Array.prototype.toArray = function() { return this; }
```

Topo was tripping up on it while enumerating over an array (it wasn't expecting to find a the `toArray` property!).

I know, it's a code smell to add enumerable properties to global objects, but it happens sometimes. This pull request will make Topo a little bit more resilient in the wide world of Javascript userland.
I think the standard way of doing this is like `graph[node].hasOwnproperty(groupIndex)`.Does that have the same effect? 

Also, `break` will terminate the loop early. You need `continue`. Finally, I think the normal approach for `for ... in` loop is 

```javascript
if (object.hasOwnproperty(key) {...}
```