diff --git a/crates/bevy_asset/src/processor/mod.rs b/crates/bevy_asset/src/processor/mod.rs index 4e5b2a878ab00..55f136f252893 100644 --- a/crates/bevy_asset/src/processor/mod.rs +++ b/crates/bevy_asset/src/processor/mod.rs @@ -506,7 +506,7 @@ impl AssetProcessor { .await? && contains_files; } - if !contains_files { + if !contains_files && path.parent().is_some() { if let Some(writer) = clean_empty_folders_writer { // it is ok for this to fail as it is just a cleanup job. let _ = writer.remove_empty_directory(&path).await;