get logs working with backbone v1 Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/56a52a1d Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/56a52a1d Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/56a52a1d
Branch: refs/heads/1720-move-to-backbone-1.0 Commit: 56a52a1d3d46080ae202efd742fab489a03eb070 Parents: 3668768 Author: Simon Metson <[email protected]> Authored: Thu Mar 21 10:53:44 2013 +0000 Committer: Simon Metson <[email protected]> Committed: Thu Mar 28 08:43:40 2013 +0000 ---------------------------------------------------------------------- src/fauxton/app/addons/logs/resources.js | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb/blob/56a52a1d/src/fauxton/app/addons/logs/resources.js ---------------------------------------------------------------------- diff --git a/src/fauxton/app/addons/logs/resources.js b/src/fauxton/app/addons/logs/resources.js index 382fafe..d1e6d20 100644 --- a/src/fauxton/app/addons/logs/resources.js +++ b/src/fauxton/app/addons/logs/resources.js @@ -12,10 +12,11 @@ define([ "app", - "api" + "api", + "backbone" ], -function (app, FauxtonAPI) { +function (app, FauxtonAPI, Backbone) { var Log = FauxtonAPI.addon(); @@ -66,7 +67,6 @@ function (app, FauxtonAPI) { parse: function (resp) { var lines = resp.split(/\n/); - return _.foldr(lines, function (acc, logLine) { var match = logLine.match(/^\[(.*?)\]\s\[(.*?)\]\s\[(.*?)\]\s(.*)/); @@ -98,7 +98,7 @@ function (app, FauxtonAPI) { this.filters = []; this.filteredCollection = new Log.Collection(this.collection.toJSON()); - this.collection.on("reset", function () { + this.collection.on("add", function () { this.createFilteredCollection(); }, this); },
