Fix how the array of models is iterated

/to @bajtos 
/cc @dashby3000 

https://github.com/strongloop/loopback-explorer/issues/49