diff options
author | John Christopher Anderson <jchris@apache.org> | 2010-01-18 03:45:54 +0000 |
---|---|---|
committer | John Christopher Anderson <jchris@apache.org> | 2010-01-18 03:45:54 +0000 |
commit | 09351a0535fe9bc3fa780763c095fd6dc56175de (patch) | |
tree | bb5940d322a8ed152c1e933c564ca51ed4ae6231 /src/couchdb/couch_httpd_db.erl | |
parent | 0a94f47f2b962048837a6a28449bfd962dd1fd3e (diff) |
normalize userCtx name and roles, also, no log in via a conflict doc
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@900275 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/couchdb/couch_httpd_db.erl')
-rw-r--r-- | src/couchdb/couch_httpd_db.erl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/couchdb/couch_httpd_db.erl b/src/couchdb/couch_httpd_db.erl index 9233e953..28efc90e 100644 --- a/src/couchdb/couch_httpd_db.erl +++ b/src/couchdb/couch_httpd_db.erl @@ -467,7 +467,11 @@ db_req(#httpd{method='POST',path_parts=[_,<<"_bulk_docs">>]}=Req, Db) -> send_json(Req, 417, ErrorsJson) end; false -> - Docs = [couch_doc:from_json_obj(JsonObj) || JsonObj <- DocsArray], + Docs = lists:map(fun(JsonObj) -> + Doc = couch_doc:from_json_obj(JsonObj), + validate_attachment_names(Doc), + Doc + end, DocsArray), {ok, Errors} = couch_db:update_docs(Db, Docs, Options, replicated_changes), ErrorsJson = lists:map(fun update_doc_result_to_json/1, Errors), |