Skip to content

Commit

Permalink
Fix clippy lints warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
Refragg committed Aug 20, 2023
1 parent 5ec7210 commit 1edfdd4
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions src/auto_splitting/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -365,13 +365,13 @@ impl Runtime {

let result = receiver.await;

return match result {
match result {
Ok(settings) => match settings {
Some(settings) => Ok(settings),
None => Err(Error::SettingsLoadFailed),
},
Err(_) => Err(Error::ThreadStopped),
};
}
}

/// Get the custom auto splitter settings
Expand All @@ -392,13 +392,13 @@ impl Runtime {

let result = receiver.await;

return match result {
match result {
Ok(setting_value) => match setting_value {
Some(setting_value) => Ok(setting_value),
None => Err(Error::SettingNotFound),
},
Err(_) => Err(Error::ThreadStopped),
};
}
}

/// Get the value for a custom auto splitter setting
Expand Down Expand Up @@ -603,10 +603,7 @@ async fn run(
log::info!(target: "Auto Splitter", "Getting the settings");
}
Request::GetSettingValue(key, ret) => {
let setting_value = match runtime.settings_store().get(key.as_str()) {
Some(value) => Some(value),
None => None,
};
let setting_value = runtime.settings_store().get(key.as_str());

let user_setting_value = match runtime
.user_settings()
Expand Down

0 comments on commit 1edfdd4

Please sign in to comment.