diff options
author | suelockwood <deathbear@apache.org> | 2014-01-03 15:16:46 -0500 |
---|---|---|
committer | suelockwood <deathbear@apache.org> | 2014-01-03 15:16:46 -0500 |
commit | b61105d759ec4ec1fa4ec7d28d32357f9df050d3 (patch) | |
tree | f911bbb22b864a336bcd9cd4d176a9bd3344d2ca | |
parent | 3ada73d04cc39fc8d37987d6a463adacc0b21195 (diff) | |
download | couchdb-b61105d759ec4ec1fa4ec7d28d32357f9df050d3.tar.gz |
remove reduce when setting view on ddoc
-rw-r--r-- | src/fauxton/app/modules/documents/resources.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/fauxton/app/modules/documents/resources.js b/src/fauxton/app/modules/documents/resources.js index 14c9ebaea..8901f5af7 100644 --- a/src/fauxton/app/modules/documents/resources.js +++ b/src/fauxton/app/modules/documents/resources.js @@ -97,10 +97,11 @@ function(app, FauxtonAPI) { if (!this.isDdoc()) return false; var views = this.get('views'); if (reduce) { - views[view].reduce=reduce; - } + views[view].reduce=reduce; + } else { + delete views[view].reduce; + } views[view].map= map; - this.set({views: views}); return true; |