mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-09-07 21:11:10 +03:00
fix clippy lint
This commit is contained in:
@@ -518,7 +518,7 @@ impl Config {
|
||||
}
|
||||
|
||||
pub fn read_from_disk(&mut self) -> Result<bool, io::Error> {
|
||||
log::info!("reading config from {:?}", &self.config_path);
|
||||
log::info!("reading config from {:?}", self.config_path);
|
||||
|
||||
let current_config = fs::read_to_string(&self.config_path)?;
|
||||
let current_config = match current_config.parse::<DocumentMut>() {
|
||||
@@ -548,7 +548,7 @@ impl Config {
|
||||
}
|
||||
|
||||
pub fn write_back(&mut self) -> Result<(), io::Error> {
|
||||
log::info!("writing config to {:?}", &self.config_path);
|
||||
log::info!("writing config to {:?}", self.config_path);
|
||||
/* the new config */
|
||||
let new_config = self.config_toml.clone().unwrap_or_default();
|
||||
let new_config = toml_edit::ser::to_string_pretty(&new_config).expect("config");
|
||||
|
||||
Reference in New Issue
Block a user