From 50ef10e7c4da378b36ac4233a7419624b990d27b Mon Sep 17 00:00:00 2001 From: Ben Savage <btsavage@fb.com> Date: Tue, 7 Nov 2023 21:55:38 +0800 Subject: [PATCH] making clippy happy --- src/protocol/ipa_prf/prf_sharding/mod.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/protocol/ipa_prf/prf_sharding/mod.rs b/src/protocol/ipa_prf/prf_sharding/mod.rs index 636a41598..5e0ae01d5 100644 --- a/src/protocol/ipa_prf/prf_sharding/mod.rs +++ b/src/protocol/ipa_prf/prf_sharding/mod.rs @@ -368,13 +368,11 @@ where while let Some(row) = s.next().await { if row.prf_of_match_key == last_row_prf { current_chunk.push(row); + } else if current_chunk.len() > 1 { + return Some((current_chunk, Some((s, row)))); } else { - if current_chunk.len() > 1 { - return Some((current_chunk, Some((s, row)))); - } else { - last_row_prf = row.prf_of_match_key; - current_chunk = vec![row]; - } + last_row_prf = row.prf_of_match_key; + current_chunk = vec![row]; } } Some((current_chunk, None))