lucian1900/Backbone.dualStorage — pull request #39 by maxpeterson (2013-06-25 10:40:56+00:00)
Title: localsync create fails when model is undefined.

This includes my earlier changes from lucian1900/Backbone.dualStorage#37, the only new change is to localsync create - I hope it not too confusing, let me know if you need me to make a better / more specific pull request.

I found that localsync was failing during create because `store.find(model)` was being called with an undefined model. My change is simply to check model and model.id exist before calling `store.find(model)`.

In this case I am creating a new item with `var model = new Model({...})` then calling `model.save()`.