Fix get_bool_cfg()

This commit is contained in:
Matthias Beyer 2016-09-07 17:13:14 +02:00
parent 9e5932f57c
commit 0e7d1730fc

View file

@ -55,12 +55,12 @@ fn get_bool_cfg(cfg: Option<&Value>, name: &str, on_fail: bool, on_unavail: bool
Some(&Value::Boolean(b)) => b, Some(&Value::Boolean(b)) => b,
Some(_) => { Some(_) => {
warn!("Configuration error, '{}' must be a Boolean (true|false).", name); warn!("Configuration error, '{}' must be a Boolean (true|false).", name);
warn!("Assuming 'true' now."); warn!("Assuming '{}' now.", on_fail);
on_fail on_fail
}, },
None => { None => {
debug!("No key '{}' - Assuming 'true'", name); debug!("No key '{}' - Assuming '{}'", name, on_unavail);
on_fail on_unavail
}, },
} }
}) })