Skip to content

Commit 48cba00

Browse files
wraitiiCopilot
andcommitted
child_idx instead of i
Co-authored-by: Copilot <[email protected]>
1 parent eab02cd commit 48cba00

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/mempool/verify_tx.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -234,16 +234,16 @@ impl super::Mempool {
234234
let mut dp = None;
235235
if let Some(buffered_proposals) = self.buffered_proposals.get_mut(&lane_id) {
236236
// Check if we have a buffered proposal that is a child of this DP
237-
let i = buffered_proposals.iter().position(|dp| {
237+
let child_idx = buffered_proposals.iter().position(|dp| {
238238
if let Some(parent_hash) = &dp.parent_data_proposal_hash {
239239
parent_hash == &hash
240240
} else {
241241
false
242242
}
243243
});
244-
if let Some(i) = i {
244+
if let Some(child_idx) = child_idx {
245245
// We have a buffered proposal that is a child of this DP
246-
dp = Some(buffered_proposals.swap_remove(i));
246+
dp = Some(buffered_proposals.swap_remove(child_idx));
247247
}
248248
}
249249
if let Some(dp) = dp {

0 commit comments

Comments
 (0)