From 664e194fe44c29bd50e899578c86792fb08cf35f Mon Sep 17 00:00:00 2001 From: DaniPopes <57450786+DaniPopes@users.noreply.github.com> Date: Fri, 20 Sep 2024 23:55:54 +0200 Subject: [PATCH] move into stream --- crates/provider/src/blocks.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/provider/src/blocks.rs b/crates/provider/src/blocks.rs index c35a55e8ef40..743fdd6f47e0 100644 --- a/crates/provider/src/blocks.rs +++ b/crates/provider/src/blocks.rs @@ -57,10 +57,10 @@ impl NewBlocks { } fn into_poll_stream(mut self) -> impl Stream + 'static { + stream! { let poll_task_builder: PollerBuilder = PollerBuilder::new(self.client.clone(), "eth_blockNumber", []); let mut poll_task = poll_task_builder.spawn().into_stream_raw(); - stream! { 'task: loop { // Clear any buffered blocks. while let Some(known_block) = self.known_blocks.pop(&self.next_yield) {