Skip to content

Commit a675d48

Browse files
tnullTheBlueMatt
authored andcommitted
Fix synchronize_listeners calling default implementation
Previously, the `ChainListenerSet` `Listen` implementation wouldn't forward to the listeners `block_connected` implementation outside of tests. This would result in the default implementation of `Listen::block_connected` being used and the listeners implementation never being called.
1 parent acfc6d9 commit a675d48

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

lightning-block-sync/src/init.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -235,8 +235,6 @@ impl<'a, L: chain::Listen + ?Sized> chain::Listen for DynamicChainListener<'a, L
235235
struct ChainListenerSet<'a, L: chain::Listen + ?Sized>(Vec<(u32, &'a L)>);
236236

237237
impl<'a, L: chain::Listen + ?Sized> chain::Listen for ChainListenerSet<'a, L> {
238-
// Needed to differentiate test expectations.
239-
#[cfg(test)]
240238
fn block_connected(&self, block: &bitcoin::Block, height: u32) {
241239
for (starting_height, chain_listener) in self.0.iter() {
242240
if height > *starting_height {

0 commit comments

Comments
 (0)