summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/config.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/config.rs b/src/config.rs
index b44445b..3dcdf85 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -31,9 +31,8 @@ impl Config {
pub fn find_config() -> Option<Config> {
for path in default_config_file_locations() {
- match Self::parse_config_file_at_path(&path) {
- Ok(config) => { return Some(config); },
- Err(_) => {},
+ if let Ok(config) = Self::parse_config_file_at_path(&path) {
+ return Some(config);
};
};
None