rnewson commented on code in PR #4673: URL: https://github.com/apache/couchdb/pull/4673#discussion_r1317842613
########## src/couch/src/couch_db.erl: ########## @@ -1864,23 +1976,35 @@ open_doc_revs_int(Db, IdRevs, Options) -> open_doc_int(Db, <<?LOCAL_DOC_PREFIX, _/binary>> = Id, Options) -> case couch_db_engine:open_local_docs(Db, [Id]) of [#doc{} = Doc] -> - apply_open_options({ok, Doc}, Options); + case Doc#doc.body of + {Body} -> + Access = couch_util:get_value(<<"_access">>, Body), + apply_open_options(Db, {ok, Doc#doc{access = Access}}, Options); + _Else -> Review Comment: will do a full review tomorrow but I am uncomfortable with a giant `_Else` here. what else would we get except a body? `undefined` or `nil`? let's be specific in couch_db.erl. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@couchdb.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org