refactor(clippy): apply various lint fixes

This commit is contained in:
LGUG2Z committed 2023-12-02 13:47:49 -08:00
1 parent 5a99a688a6
commit 1c589491a9
2 files changed
+6 -5

No files matched your search

+5 -4
View File
@@ -509,16 +509,17 @@ fn main() -> Result<()> {
Hidden::create("komorebi-hidden")?;
let static_config = if let Some(config) = opts.config {
Option::from(config)
} else {
let static_config = opts.config.map_or_else(
|| {
let komorebi_json = HOME_DIR.join("komorebi.json");
if komorebi_json.is_file() {
Option::from(komorebi_json)
} else {
None
}
};
},
Option::from,
);
let wm = if let Some(config) = &static_config {
tracing::info!(
+1 -1
View File
@@ -700,7 +700,7 @@ impl WindowsApi {
Self::system_parameters_info_w(
SPI_SETFOREGROUNDLOCKTIMEOUT,
0,
0 as *mut c_void,
std::ptr::null_mut::<c_void>(),
SPIF_SENDCHANGE,
)?;