couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From deathb...@apache.org
Subject git commit: updated refs/heads/1807-Replication to 402efe8
Date Mon, 09 Sep 2013 14:29:00 GMT
Updated Branches:
  refs/heads/1807-Replication 38970f1d1 -> 402efe8f9


Should use _.filter, not _.map when pulling out all the replication active tasks.


Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/402efe8f
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/402efe8f
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/402efe8f

Branch: refs/heads/1807-Replication
Commit: 402efe8f916ff998bda3909754612b5f73f32ad9
Parents: 38970f1
Author: suelockwood <deathbearbrown@gmail.com>
Authored: Mon Sep 9 10:28:59 2013 -0400
Committer: suelockwood <deathbearbrown@gmail.com>
Committed: Mon Sep 9 10:28:59 2013 -0400

----------------------------------------------------------------------
 src/fauxton/app/addons/replication/resources.js | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/402efe8f/src/fauxton/app/addons/replication/resources.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/replication/resources.js b/src/fauxton/app/addons/replication/resources.js
index 67b474a..62cb3d1 100644
--- a/src/fauxton/app/addons/replication/resources.js
+++ b/src/fauxton/app/addons/replication/resources.js
@@ -52,10 +52,8 @@ function (app, FauxtonAPI, ActiveTasks) {
     },
     parse: function(resp){
       //only want replication tasks to return
-      return _.map(resp, function(task){
-        if (task.type === "replication"){
-          return task;
-        }
+      return _.filter(resp, function(task){
+        return task["type"] === "replication";
       });
     }
   });


Mime
View raw message