coderenaissance / knockout.viewmodel

The knockout viewmodel plugin is the fastest, smallest, cleanest, most flexible way to create a knockout viewmodel.
http://coderenaissance.github.com/knockout.viewmodel
105 stars 27 forks source link

Update knockout.viewmodel.js #69

Open armindojcunha opened 8 years ago

armindojcunha commented 8 years ago

This was a problem that I detect on the display of the information when was updating recursive the viewmodel from the new model. Because when we remove a element:

viewModelObj.splice(q, 1);

If we use the slice over the object and not the function we cannot guaranty the order so we don't display the correct information.

So simply change to viewModelObj().splice(q, 1); will fix this problem.