summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/couchdb/couch_rep.erl8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/couchdb/couch_rep.erl b/src/couchdb/couch_rep.erl
index 0e7c1012..e0c4d470 100644
--- a/src/couchdb/couch_rep.erl
+++ b/src/couchdb/couch_rep.erl
@@ -182,10 +182,12 @@ do_http_request(Url, Action, Headers, JsonBody, Retries) ->
_ ->
iolist_to_binary(?JSON_ENCODE(JsonBody))
end,
- Options = [
+ Options = case Action of
+ get -> [];
+ _ -> [{transfer_encoding, {chunked, 65535}}]
+ end ++ [
{content_type, "application/json; charset=utf-8"},
- {max_pipeline_size, 101},
- {transfer_encoding, {chunked, 65535}}
+ {max_pipeline_size, 101}
],
case ibrowse:send_req(Url, Headers, Action, Body, Options) of
{ok, Status, ResponseHeaders, ResponseBody} ->