From 3978feeb5bb3524df21e07825be9dd630a671750 Mon Sep 17 00:00:00 2001 From: a-kenji Date: Fri, 19 Jul 2024 11:39:59 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=A8=20Fix=20clippy=20warnings?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/main.rs | 2 +- client/src/plugin/applications.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/main.rs b/client/src/main.rs index 1047234..2877959 100644 --- a/client/src/main.rs +++ b/client/src/main.rs @@ -399,7 +399,7 @@ impl Centerpiece { Some(active_entry_id) => self .plugins .iter() - .filter(|plugin| plugin.entries.len() > 0) + .filter(|plugin| !plugin.entries.is_empty()) .position(|plugin| { plugin .entries diff --git a/client/src/plugin/applications.rs b/client/src/plugin/applications.rs index 47ebf2a..7e9b772 100644 --- a/client/src/plugin/applications.rs +++ b/client/src/plugin/applications.rs @@ -11,7 +11,7 @@ fn to_entry( ) -> Option { let title = name(desktop_entry); - if !is_visible(&desktop_entry) { + if !is_visible(desktop_entry) { log::debug!(target: "applications", "Desktop entry with name '{}' will be hidden because of its properties.", title); return None; } @@ -98,7 +98,7 @@ fn is_visible(desktop_entry: &freedesktop_desktop_entry::DesktopEntry) -> bool { fn terminal_command(desktop_entry: &freedesktop_desktop_entry::DesktopEntry) -> Option { if !desktop_entry .categories()? - .split(";") + .split(';') .any(|category| category == "TerminalEmulator") { return None;