noveogroup / backbone.iobind

Bind socket.io events to backbone models & collections. Also includes a drop-in replacement for Backbone.sync using socket.io.
https://noveogroup.github.io/backbone.iobind/
582 stars 65 forks source link

.fetch() on model is broken. #52

Closed geon closed 9 years ago

geon commented 10 years ago

When fetching a single model, the slash and id in the URL are stripped off, and the request is sent to the collection instead, so all models in the collection are added as properties on the model being "fetched".

A simple workaround is to never fetch a model, but the entire collection instead.

mahnunchik commented 10 years ago

@geon Hi, Curren implementation should send id as socketio payload. And shoul fetch only fetched model. If it is not so could you provide simple test case