From 8989e32b05b54c3cbb86e618a4435fb4028a81bb Mon Sep 17 00:00:00 2001 From: Willem Wyndham Date: Tue, 12 Mar 2024 09:48:46 -0400 Subject: [PATCH] chore: use `map_or` --- cmd/soroban-cli/build.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cmd/soroban-cli/build.rs b/cmd/soroban-cli/build.rs index 82e17a1059..196e93c4af 100644 --- a/cmd/soroban-cli/build.rs +++ b/cmd/soroban-cli/build.rs @@ -118,7 +118,6 @@ mod build_helper { fn file_exists(file_path: &Path) -> bool { metadata(file_path) .as_ref() - .map(Metadata::is_file) - .unwrap_or(false) + .map_or(false, Metadata::is_file) } }