summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn Christopher Anderson <jchris@apache.org>2010-07-13 14:25:06 +0000
committerJohn Christopher Anderson <jchris@apache.org>2010-07-13 14:25:06 +0000
commit32c60cf5c554a1ff3819cc658ebf5846ccb9d6be (patch)
tree35af2d7e9d2c78a42fcfa662debe238db1c51d7a /src
parent934693735ad6c6358a240a466d4ce121f150e1aa (diff)
show the complete document body even when the document is deleted (Couch lets you store data with a delete but did not render it to JSON)
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@963725 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r--src/couchdb/couch_doc.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/couchdb/couch_doc.erl b/src/couchdb/couch_doc.erl
index 50dbd9d0..acae0c55 100644
--- a/src/couchdb/couch_doc.erl
+++ b/src/couchdb/couch_doc.erl
@@ -27,8 +27,8 @@ to_json_rev(0, []) ->
to_json_rev(Start, [FirstRevId|_]) ->
[{<<"_rev">>, ?l2b([integer_to_list(Start),"-",revid_to_str(FirstRevId)])}].
-to_json_body(true, _Body) ->
- [{<<"_deleted">>, true}];
+to_json_body(true, {Body}) ->
+ Body ++ [{<<"_deleted">>, true}];
to_json_body(false, {Body}) ->
Body.