summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBenoit Chesneau <benoitc@apache.org>2010-08-18 18:54:40 +0000
committerBenoit Chesneau <benoitc@apache.org>2010-08-18 18:54:40 +0000
commit1f729f7f261f9607b74b6c8723e190720db8dc32 (patch)
tree5748a7900e02b409811b9804d4e7fa1fc5a75c44 /src
parent4b0f69f2fa9a8a6ead5ad62c1ebacfc50ede4591 (diff)
expose security obj to shows, lists & updates functions.
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@986854 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r--src/couchdb/couch_httpd_external.erl6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/couchdb/couch_httpd_external.erl b/src/couchdb/couch_httpd_external.erl
index 84ac44d3..f8d6f171 100644
--- a/src/couchdb/couch_httpd_external.erl
+++ b/src/couchdb/couch_httpd_external.erl
@@ -73,7 +73,8 @@ json_req_obj(#httpd{mochi_req=Req,
Headers = Req:get(headers),
Hlist = mochiweb_headers:to_list(Headers),
{ok, Info} = couch_db:get_db_info(Db),
- % add headers...
+
+% add headers...
{[{<<"info">>, {Info}},
{<<"id">>, DocId},
{<<"uuid">>, couch_uuids:new()},
@@ -86,7 +87,8 @@ json_req_obj(#httpd{mochi_req=Req,
{<<"peer">>, ?l2b(Req:get(peer))},
{<<"form">>, to_json_terms(ParsedForm)},
{<<"cookie">>, to_json_terms(Req:parse_cookie())},
- {<<"userCtx">>, couch_util:json_user_ctx(Db)}]}.
+ {<<"userCtx">>, couch_util:json_user_ctx(Db)},
+ {<<"secObj">>, couch_db:get_security(Db)}]}.
to_json_terms(Data) ->
to_json_terms(Data, []).