From 74f9f11bbc53edb0d741a912eabde68168795d6a Mon Sep 17 00:00:00 2001 From: Christian Hughes Date: Sun, 25 Aug 2024 22:00:31 -0500 Subject: [PATCH] fix doctest --- crates/bevy_ecs/src/observer/data.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/bevy_ecs/src/observer/data.rs b/crates/bevy_ecs/src/observer/data.rs index 4854c64dfa1aa..4734d2e104a36 100644 --- a/crates/bevy_ecs/src/observer/data.rs +++ b/crates/bevy_ecs/src/observer/data.rs @@ -103,7 +103,7 @@ unsafe impl EventData for E { /// let on_remove = world.init_component::(); /// /// world.spawn( -/// Observer::new(|trigger: Trigger| { +/// Observer::new(|mut trigger: Trigger| { /// // This observer function is called for both OnAdd and OnRemove events! /// let ptr_mut = trigger.event_mut(); /// // do something with the PtrMut, if needed