I am making a service call using collection url. The service returns some json, the json length is 13 (in short 13 rows of data).
Here, this.Collection.fetch() is returning json who's length is 13. but this.Collection.toJSON() is returning json who's length is 12. instead it should return length 13.
In collection parse, the response is returning json who's length is 13, which is correct!
tableTemplate is object of template (template is done using Handlebars.js).
this.Collection.fetch({ success: function(){
console.log("Collection Fetch 2:");
console.log(this.Collection.fetch());
console.log("Collection toJSON: ");
console.log(this.Collection.toJSON());
console.log(this.Collection.toJSON().length);
var markup = tableTemplate({List:self.importCollection.toJSON()});
...
...
}
});