Revert "Revert "refactoring backbone urls"" This reverts commit838da1fd52. Revert "revert9b1d64bb76as it is causing inf. scroll to break (stream model now has a post collection)" This reverts commit2a69c0ebd4.
7 lines
292 B
JavaScript
7 lines
292 B
JavaScript
app.collections.Comments = Backbone.Collection.extend({
|
|
model: app.models.Comment,
|
|
|
|
initialize : function(models, options) {
|
|
this.url = "/posts/" + options.post.id + "/comments" //not delegating to post.url() because when it is in a stream collection it delegates to that url
|
|
}
|
|
});
|