anchor.diff:      case couch_server:open(DbName, Options) of
           {ok, Db} ->
               try
  -                check_is_reader(Db),
  +                check_is_member(Db),
                   {ok, Db}
               catch
                   throw:Error ->
  
positive.code:         ok
      end.
  
  check_is_reader(#db{user_ctx=#user_ctx{name=Name,roles=Roles}=UserCtx}=Db) ->
      case (catch check_is_admin(Db)) of
      ok -> ok;
      _ ->
          {Readers} = get_readers(Db),
          ReaderRoles = couch_util:get_value(<<"roles">>, Readers,[]),
          WithAdminRoles = [<<"_admin">> | ReaderRoles],
          ReaderNames = couch_util:get_value(<<"names">>, Readers,[]),
          case ReaderRoles ++ ReaderNames of
          [] -> ok; % no readers == public access
          _Else ->
  
negative.code: get_admins(#db{security=SecProps}) ->
      couch_util:get_value(<<"admins">>, SecProps, {[]}).
  
  get_members(#db{security=SecProps}) ->
      % we fallback to readers here for backwards compatibility
      couch_util:get_value(<<"members">>, SecProps,
          couch_util:get_value(<<"readers">>, SecProps, {[]})).
  
  get_security(#db{security=SecProps}) ->
      {SecProps}.
  