bin: replace .unwrap_or
with .map_or
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
This commit is contained in:
parent
5d4ed07f1c
commit
6d7fef078e
@ -156,9 +156,7 @@ fn make_opts() -> Options {
|
||||
}
|
||||
|
||||
fn is_nightly() -> bool {
|
||||
option_env!("CFG_RELEASE_CHANNEL")
|
||||
.map(|c| c == "nightly" || c == "dev")
|
||||
.unwrap_or(false)
|
||||
option_env!("CFG_RELEASE_CHANNEL").map_or(false, |c| c == "nightly" || c == "dev")
|
||||
}
|
||||
|
||||
// Returned i32 is an exit code
|
||||
|
Loading…
x
Reference in New Issue
Block a user