mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
perf: allocate responses capacity (#618)
This commit is contained in:
@ -135,7 +135,7 @@ where
|
||||
|
||||
let mut bodies = bodies.into_iter();
|
||||
|
||||
let mut responses = vec![];
|
||||
let mut responses = Vec::with_capacity(headers.len());
|
||||
for header in headers.into_iter().cloned() {
|
||||
// If the header has no txs / ommers, just push it and continue
|
||||
if header.is_empty() {
|
||||
|
||||
Reference in New Issue
Block a user