diff --git a/ecs/src/entity.rs b/ecs/src/entity.rs index dbb6b1e..87a1bf7 100644 --- a/ecs/src/entity.rs +++ b/ecs/src/entity.rs @@ -69,8 +69,10 @@ impl std::fmt::Debug for EntityObject { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { let mut t = f.debug_struct("EntityObject"); - t.field("debug_name", &self.debug_name) - .field("gltf_file", &self.gltf_file) + #[cfg(debug_assertions)] + t.field("debug_name", &self.debug_name); + + t.field("gltf_file", &self.gltf_file) .field("activation_state", &self.activation_state) .field("entity_id", &self.entity_id);