Skip to content

Commit

Permalink
Fix the asset_processing example failing to compile.
Browse files Browse the repository at this point in the history
  • Loading branch information
andriyDev committed Oct 31, 2024
1 parent ad0c259 commit 547a3df
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions examples/asset/processing/asset_processing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,23 +146,23 @@ impl AssetLoader for CoolTextLoader {
let ron: CoolTextRon = ron::de::from_bytes(&bytes)?;
let mut base_text = ron.text;
for embedded in ron.embedded_dependencies {
let loaded = load_context
let complete_loaded = load_context
.loader()
.immediate()
.load::<Text>(&embedded)
.await?;
base_text.push_str(&loaded.get().0);
base_text.push_str(&complete_loaded.get_asset().get().0);
}
for (path, settings_override) in ron.dependencies_with_settings {
let loaded = load_context
let complete_loaded = load_context
.loader()
.with_settings(move |settings| {
*settings = settings_override.clone();
})
.immediate()
.load::<Text>(&path)
.await?;
base_text.push_str(&loaded.get().0);
base_text.push_str(&complete_loaded.get_asset().get().0);
}
Ok(CoolText {
text: base_text,
Expand Down

0 comments on commit 547a3df

Please sign in to comment.