diff --git a/crates/bevy_asset/src/path.rs b/crates/bevy_asset/src/path.rs index 3f780e3fb7..ed189a683b 100644 --- a/crates/bevy_asset/src/path.rs +++ b/crates/bevy_asset/src/path.rs @@ -480,7 +480,7 @@ impl<'a> AssetPath<'a> { } pub(crate) fn iter_secondary_extensions(full_extension: &str) -> impl Iterator { - full_extension.chars().enumerate().filter_map(|(i, c)| { + full_extension.char_indices().filter_map(|(i, c)| { if c == '.' { Some(&full_extension[i + 1..]) } else {