diff --git a/crates/bevy_pbr/src/render/morph.rs b/crates/bevy_pbr/src/render/morph.rs index 7516bb495b7f1..cdc9c599ea24b 100644 --- a/crates/bevy_pbr/src/render/morph.rs +++ b/crates/bevy_pbr/src/render/morph.rs @@ -109,6 +109,6 @@ pub fn no_automatic_morph_batching( query: Query, Without)>, ) { for entity in &query { - commands.entity(entity).insert(NoAutomaticBatching); + commands.entity(entity).try_insert(NoAutomaticBatching); } } diff --git a/crates/bevy_pbr/src/render/skin.rs b/crates/bevy_pbr/src/render/skin.rs index 8ad3c35d6ee47..6a725b546c5e3 100644 --- a/crates/bevy_pbr/src/render/skin.rs +++ b/crates/bevy_pbr/src/render/skin.rs @@ -146,6 +146,6 @@ pub fn no_automatic_skin_batching( query: Query, Without)>, ) { for entity in &query { - commands.entity(entity).insert(NoAutomaticBatching); + commands.entity(entity).try_insert(NoAutomaticBatching); } }