def error_target

bendvy-ecs-core@0.1.0.4 · relation_reorder.bend:23

import bendvy-ecs-core@0.1.0.4/relation_reorder.bend as RelationReorder
import Base
import entity_key.bend as Key
import relation_types.bend as G

23def error_target(error:G.Error,parent:Key.Key) -> Key.Key:
24  match error:
25    case G.MissingChildEntity{_,child,_}: child
26    case G.DuplicateChild{_,child,_}: child
27    case G.ChildNotRelatedToParent{_,child,_}: child
28    case _: parent

Uses (2)

Used by (1)