unwrap
on option_env!
macro RS-W1016Unwrapping the result of the option_env!
macro will panic at runtime if the
environment variable does not exist. The env!
macro catches this at compile
time.
Replace the call to option_env!(...).unwrap()
with env!(...)
.
option_env!("HOME").unwrap();
env!("HOME");