Skip to content

Commit f3cbe42

Browse files
committed
gate import on bevy_animation in bevy_gltf (#18403)
# Objective - `collect_path` is only declared when feature `bevy_animation` is enabled - it is imported without checking for the feature, not compiling when not enabled ## Solution - Gate the import
1 parent 920515a commit f3cbe42

File tree

1 file changed

+3
-1
lines changed
  • crates/bevy_gltf/src/loader

1 file changed

+3
-1
lines changed

crates/bevy_gltf/src/loader/mod.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ use crate::{
6666
GltfMaterialName, GltfMeshExtras, GltfNode, GltfSceneExtras, GltfSkin,
6767
};
6868

69+
#[cfg(feature = "bevy_animation")]
70+
use self::gltf_ext::scene::collect_path;
6971
use self::{
7072
extensions::{AnisotropyExtension, ClearcoatExtension, SpecularExtension},
7173
gltf_ext::{
@@ -75,7 +77,7 @@ use self::{
7577
warn_on_differing_texture_transforms,
7678
},
7779
mesh::{primitive_name, primitive_topology},
78-
scene::{collect_path, node_name, node_transform},
80+
scene::{node_name, node_transform},
7981
texture::{texture_handle, texture_sampler, texture_transform_to_affine2},
8082
},
8183
};

0 commit comments

Comments
 (0)