anchor.diff:  -export([handle_doc_show_req/3, handle_doc_update_req/3, handle_view_list_req/3]).
   
   -include_lib("couch/include/couch_db.hrl").
  -
  --record(lacc, {
  -    req,
  -    resp = nil,
  -    qserver,
  -    lname,
  -    db,
  -    etag
  -}).
  +-include_lib("couch_mrview/include/couch_mrview.hrl").
   
   % /db/_design/foo/_show/bar/docid
   % show converts a json doc to a response of any content-type. 
  
positive.code: handle_view_list(Req, Db, DDoc, LName, {ViewDesignName, ViewName}, Keys) ->
      %% Will throw an exception if the _list handler is missing
      couch_util:get_nested_json_value(DDoc#doc.body, [<<"lists">>, LName]),
      {ok, VDoc} = fabric:open_doc(Db, <<"_design/", ViewDesignName/binary>>, []),
      Group = couch_view_group:design_doc_to_view_group(VDoc),
      IsReduce = chttpd_view:get_reduce_type(Req),
      ViewType = chttpd_view:extract_view_type(ViewName,
          couch_view_group:get_views(Group), IsReduce),
      QueryArgs = chttpd_view:parse_view_params(Req, Keys, ViewType),
      CB = fun list_callback/2,
      Etag = couch_uuids:new(),
      chttpd:etag_respond(Req, Etag, fun() ->
          couch_query_servers:with_ddoc_proc(DDoc, fun(QServer) ->
              Acc0 = #lacc{
  
negative.code:         path_parts=[_, _, DesignName, _, ListName, ViewName]}=Req, Db, DDoc) ->
      ReqBody = chttpd:body(Req),
      {Props2} = ?JSON_DECODE(ReqBody),
      Keys = proplists:get_value(<<"keys">>, Props2, undefined),
      handle_view_list(Req#httpd{req_body=ReqBody}, Db, DDoc, ListName,
          {DesignName, ViewName}, Keys);
  
  