Skip to content

Commit 52007c1

Browse files
committed
f - Use hidden FakeLogger in docs
1 parent ec9734f commit 52007c1

File tree

1 file changed

+7
-2
lines changed
  • lightning-rapid-gossip-sync/src

1 file changed

+7
-2
lines changed

lightning-rapid-gossip-sync/src/lib.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,16 @@
3030
//! use bitcoin::blockdata::constants::genesis_block;
3131
//! use bitcoin::Network;
3232
//! use lightning::routing::gossip::NetworkGraph;
33-
//! use lightning::util::test_utils::TestLogger;
3433
//! use lightning_rapid_gossip_sync::RapidGossipSync;
3534
//!
35+
//! # use lightning::util::logger::{Logger, Record};
36+
//! # struct FakeLogger {}
37+
//! # impl Logger for FakeLogger {
38+
//! # fn log(&self, record: &Record) { unimplemented!() }
39+
//! # }
40+
//! # let logger = FakeLogger {};
41+
//!
3642
//! let block_hash = genesis_block(Network::Bitcoin).header.block_hash();
37-
//! let logger = TestLogger::new();
3843
//! let network_graph = NetworkGraph::new(block_hash, &logger);
3944
//! let rapid_sync = RapidGossipSync::new(&network_graph);
4045
//! let new_last_sync_timestamp_result = rapid_sync.sync_network_graph_with_file_path("./rapid_sync.lngossip");

0 commit comments

Comments
 (0)