Skip to main content

apply_crud_to_entity

Function apply_crud_to_entity 

Source
fn apply_crud_to_entity<E: Entity + Clone>(
    map: &mut BTreeMap<E::Id, Arc<E>>,
    id: E::Id,
    crud: &Crud<E, E::Update>,
) -> Option<()>
Expand description

None means the id is invalid for the op: unknown for Update/Delete, already taken for Create — the allocator never re-mints a number the document has held, so a duplicate create is a replay or a bug, never a merge.