refactor(net): use VecDeque::pop_front_if from Rust 1.93 (#22260)

This commit is contained in:
Tomass
2026-02-17 08:46:56 +00:00
committed by GitHub
parent e972d9d8c7
commit e21a174737

View File

@@ -245,8 +245,7 @@ where
}
// Buffer any empty headers
while this.pending_headers.front().is_some_and(|h| h.is_empty()) {
let header = this.pending_headers.pop_front().unwrap();
while let Some(header) = this.pending_headers.pop_front_if(|h| h.is_empty()) {
this.buffer.push(BlockResponse::Empty(header));
}
}