From e6fe7126c88893dd39cec32481b05f7c38e97475 Mon Sep 17 00:00:00 2001 From: Adam Kocoloski Date: Thu, 17 Jun 2010 11:48:06 -0400 Subject: correct handling of PUTs to missing DB --- src/fabric_doc_update.erl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/fabric_doc_update.erl b/src/fabric_doc_update.erl index 555b1897..4d8ca3a6 100644 --- a/src/fabric_doc_update.erl +++ b/src/fabric_doc_update.erl @@ -43,7 +43,11 @@ handle_message({ok, Replies}, Worker, Acc0) -> {_, N} when N < DocCount -> % no point in trying to finalize anything yet {ok, {WaitingCount - 1, DocCount, W, GroupedDocs, DocReplyDict}} - end. + end; +handle_message({not_found, no_db_file} = X, Worker, Acc0) -> + {_, _, _, GroupedDocs, _} = Acc0, + Docs = couch_util:get_value(Worker, GroupedDocs), + handle_message({ok, [X || _D <- Docs]}, Worker, Acc0). force_reply(Doc, Replies, {W, Acc}) -> % TODO make a real decision here -- cgit v1.2.3