[#162,refactor][s]: backend fetch method dataset argument is simple JS object not backbone Dataset.

* Helps make Backends simpler and more independent of Model
This commit is contained in:
Rufus Pollock
2012-06-23 21:36:31 +01:00
parent 3f37da089a
commit dd45991321
4 changed files with 15 additions and 7 deletions

View File

@@ -79,7 +79,7 @@ my.Dataset = Backbone.Model.extend({
var dfd = $.Deferred();
// TODO: fail case;
if (this.backend !== recline.Backend.Memory) {
this.backend.fetch(this).then(handleResults)
this.backend.fetch(this.toJSON()).then(handleResults)
} else {
// special case where we have been given data directly
handleResults({