From 53a78e1c2f127664119a03b1995e1ee74f4dcb33 Mon Sep 17 00:00:00 2001 From: timokoesters Date: Tue, 30 Apr 2019 20:01:47 +0200 Subject: [PATCH] Remove unnecessary debug from try_open_with_path Former-commit-id: 891d24c247d15f406ebd24ca923b62e6f43bf9ea --- common/src/assets/mod.rs | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/common/src/assets/mod.rs b/common/src/assets/mod.rs index 866b320ebf..68ee1433b1 100644 --- a/common/src/assets/mod.rs +++ b/common/src/assets/mod.rs @@ -108,16 +108,7 @@ fn try_open_with_path(name: &str) -> Option { ] .into_iter() .map(|bp| [bp, name].concat()) - .find_map(|ref filename| match File::open(filename) { - Ok(file) => { - debug!("Loading {} successful", filename); - Some(file) - } - Err(err) => { - error!("Loading {} failed: {}", filename, err); - None - } - }) + .find_map(|ref filename| File::open(filename).ok()) } pub fn load_from_path(name: &str) -> Result, Error> {