From 93f1acf48416aeee536fca4e0a355b5fb72c0260 Mon Sep 17 00:00:00 2001 From: Valentin Haudiquet Date: Tue, 17 Nov 2026 10:35:49 +0100 Subject: [PATCH] clippy: fold the series filter into an early return Clippy 1.91 flags the negated three-term conjunction in series_patches_to_apply; an early return keeps the intent readable without the lint. --- src/deb/local.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/deb/local.rs b/src/deb/local.rs index 4da4e6c..b65bd80 100644 --- a/src/deb/local.rs +++ b/src/deb/local.rs @@ -1624,9 +1624,10 @@ fn series_patches_to_apply(series_content: &str, single_debian_patch: bool) -> V .lines() .map(str::trim) .filter(|entry| { - !entry.is_empty() - && !entry.starts_with('#') - && !(single_debian_patch && is_debian_changes(entry)) + if entry.is_empty() || entry.starts_with('#') { + return false; + } + !(single_debian_patch && is_debian_changes(entry)) }) .collect() }