Skip to content

Commit

Permalink
env-resolver: remove panic on missed var (missed part)
Browse files Browse the repository at this point in the history
  • Loading branch information
boozook committed May 28, 2024
1 parent e8c02cc commit c9ac85f
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions support/build/src/assets/resolver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,7 @@ impl EnvResolver {

let var = std::env::var(name).map_err(log_err)
.map(Cow::from)
.unwrap_or_else(|_| {
// XXX: should we panic here?
panic!("Env var \"{name}\" not found")
});
.unwrap_or_else(|_| name.into());
replaced = replaced.replace(full, &var);
}
}
Expand Down

0 comments on commit c9ac85f

Please sign in to comment.