diff options
author | suelockwood <deathbear@apache.org> | 2014-01-03 15:05:00 -0500 |
---|---|---|
committer | suelockwood <deathbear@apache.org> | 2014-01-03 15:05:00 -0500 |
commit | 3ada73d04cc39fc8d37987d6a463adacc0b21195 (patch) | |
tree | ccc2e1cfc2b9702fa0a4108f5e546c4c4936c122 | |
parent | cdb1218123486eb3abf51706b1bd5c1fe7eb7241 (diff) | |
download | couchdb-3ada73d04cc39fc8d37987d6a463adacc0b21195.tar.gz |
Fix for setting Ddoc values on view save
-rw-r--r-- | src/fauxton/app/modules/documents/resources.js | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/fauxton/app/modules/documents/resources.js b/src/fauxton/app/modules/documents/resources.js index 8dd283b91..14c9ebaea 100644 --- a/src/fauxton/app/modules/documents/resources.js +++ b/src/fauxton/app/modules/documents/resources.js @@ -96,17 +96,10 @@ function(app, FauxtonAPI) { setDdocView: function (view, map, reduce) { if (!this.isDdoc()) return false; var views = this.get('views'); - if (reduce) { - views[view] = { - map: map, - reduce: reduce - }; - } else { - views[view] = { - map: map - }; - } + views[view].reduce=reduce; + } + views[view].map= map; this.set({views: views}); |