-
Type:
Bug
-
Status: Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 0.10
-
Fix Version/s: 1.4.0
-
Component/s: JavaScript View Server
-
Labels:None
-
Environment:{"couchdb":"Welcome","version":"0.10.0a796218"}
Linux
-
Skill Level:Regular Contributors Level (Easy to Medium)
After calling getRow() once, the response header are locked and cannot be changed by respondWith.
getRow() should be side-effect free and Sending shouldn't start before calling send();
Example, where respondWith() cannot set "Content-Type" response header according to "Accept" request header:
function(head, req){
var row = getRow();
respondWith(req,
{
json : function() {
send("
");
},
xml : function()
});
}
- is duplicated by
-
COUCHDB-764 first call to getRow() in list function forces headers
-
- Closed
-
-
COUCHDB-1299 Request to support sending list result content-type after getRow was invoked
-
- Closed
-