backbone-couchdb icon indicating copy to clipboard operation
backbone-couchdb copied to clipboard

Override Backbone.Model.clone correctly

Open rjcorwin opened this issue 8 years ago • 0 comments

This has been a mistake for a long time but it seems that older versions of Backbone have been more forgiving.

An older backbone where we were lucky it worked with backbone-couchdb.js: https://github.com/jashkenas/backbone/blob/0.9.2/backbone.js#L450

A recent backbone Backbone.Model.clone where we get weird results when using backbone-couchdb.js: https://github.com/jashkenas/backbone/blob/1.2.3/backbone.js#L707

The forgiveness happens in the constructor. Even if it used to work when used incorrectly, it definitely doesn't work now and this needs to be fixed.

rjcorwin avatar Jun 15 '16 19:06 rjcorwin